Check-in [e3ddb480d5]
Overview
Comment:Improved "appfs-mkfs" latest detection
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: e3ddb480d57871627093300d1b03e2fc19b43eb6
User & Date: rkeene on 2015-03-16 15:36:45
Other Links: manifest | tags
Context
2015-03-18
17:20
Added basic support for removing the world/group permissions from files check-in: 152a83b125 user: rkeene tags: trunk
2015-03-16
15:36
Improved "appfs-mkfs" latest detection check-in: e3ddb480d5 user: rkeene tags: trunk
2015-02-24
19:20
Improved Slackware package building script check-in: 516e8e6dd7 user: rkeene tags: trunk
Changes

Modified appfs-mkfs from [d5deebecbf] to [6085412bf1].

216
217
218
219
220
221
222

223
224
225
226
227
228
229
230
231
232




233
234
235
236
237
238
239
240
241
242
243
244
245
		package = $1;
		version = $2;
		os = $3;
		cpuArch = $4;
		hash = $5;
		isLatest = $6;


		key = package "," version "," os "," cpuArch;

		if (isLatest == "1") {
			keys_latest[key] = hash;
		}
		keys[key] = hash;
	}

	END{
		for (key in keys) {




			if (keys_latest[key] != "") {
				isLatest = "1";
				hash = keys_latest[key];
			} else {
				isLatest = "0";
				hash = keys[key];
			}

			print key "," hash "," isLatest;
		}
	}  
' | sort -u > "${packagelistfile}.new"
cat "${packagelistfile}.new" > "${packagelistfile}"







>



|






>
>
>
>
|

<


<







216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239

240
241

242
243
244
245
246
247
248
		package = $1;
		version = $2;
		os = $3;
		cpuArch = $4;
		hash = $5;
		isLatest = $6;

		latestKey = package "," os "," cpuArch;
		key = package "," version "," os "," cpuArch;

		if (isLatest == "1") {
			keys_latest[latestKey] = hash;
		}
		keys[key] = hash;
	}

	END{
		for (key in keys) {
			hash = keys[key];
			split(key, keyParts, /,/);
			latestKey = keyParts[1] "," keyParts[3] "," keyParts[4];

			if (keys_latest[latestKey] == hash) {
				isLatest = "1";

			} else {
				isLatest = "0";

			}

			print key "," hash "," isLatest;
		}
	}  
' | sort -u > "${packagelistfile}.new"
cat "${packagelistfile}.new" > "${packagelistfile}"