Update .local/share/chezmoi/home/dot_local/bin/executable_install-program

This commit is contained in:
Brian Zalewski 2022-12-05 06:23:18 +00:00
parent b505162e79
commit 62325c8243

View file

@ -133,78 +133,57 @@ async function generateInstallOrders() {
softwarePackages[packageKey][preference + ":" + osType] || softwarePackages[packageKey][preference + ":" + osType] ||
softwarePackages[packageKey][preference] softwarePackages[packageKey][preference]
) { ) {
let currentPkgRef;
if (softwarePackages[packageKey][preference + ":" + osID]) {
currentPkgRef = preference + ":" + osID;
} else if (softwarePackages[packageKey][preference + ":" + osType]) {
currentPkgRef = preference + ":" + osType;
} else if (softwarePackages[packageKey][preference]) {
currentPkgRef = preference;
}
// Handle the _when attribute // Handle the _when attribute
currentSelector = "when"; currentSelector = "when";
doubleScoped = doubleScoped =
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference + ":" + osID "_" + currentSelector + ":" + preference + ":" + osID
]) || ] ||
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osID + ":" + preference "_" + currentSelector + ":" + osID + ":" + preference
]) || ] ||
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference + ":" + osType "_" + currentSelector + ":" + preference + ":" + osType
]) || ] ||
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osType + ":" + preference "_" + currentSelector + ":" + osType + ":" + preference
]); ];
scopedPkgManager = scopedPkgManager =
softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference "_" + currentSelector + ":" + preference
]; ];
scopedSystem = scopedSystem =
(softwarePackages[currentPkgRef] && softwarePackages[packageKey]["_" + currentSelector + ":" + osID] ||
softwarePackages[currentPkgRef][ softwarePackages[packageKey]["_" + currentSelector + ":" + osType];
"_" + currentSelector + ":" + osID normalCheck = softwarePackages[currentPkgRef]["_" + currentSelector];
]) || console.log("NorMIE");
(softwarePackages[currentPkgRef] && console.log(currentPkgRef);
softwarePackages[currentPkgRef][ console.log(normalCheck);
"_" + currentSelector + ":" + osType
]);
normalCheck =
softwarePackages[currentPkgRef] &&
softwarePackages[currentPkgRef]["_" + currentSelector];
console.log('NorMIE')
console.log(normalCheck)
if (doubleScoped) { if (doubleScoped) {
try { try {
await $doubleScoped; await $doubleScoped;
} catch (e) { } catch (e) {
let pref; let pref;
if ( if (
softwarePackages[currentPkgRef][ softwarePackages[packageKey][
"_" + currentSelector + ":" + preference + ":" + osID "_" + currentSelector + ":" + preference + ":" + osID
] ]
) { ) {
pref = preference + ":" + osID; pref = preference + ":" + osID;
} else if ( } else if (
softwarePackages[currentPkgRef][ softwarePackages[packageKey][
"_" + currentSelector + ":" + preference + ":" + osType "_" + currentSelector + ":" + preference + ":" + osType
] ]
) { ) {
pref = preference + ":" + osType; pref = preference + ":" + osType;
} else if ( } else if (
softwarePackages[currentPkgRef][ softwarePackages[packageKey][
"_" + currentSelector + ":" + osID + ":" + preference "_" + currentSelector + ":" + osID + ":" + preference
] ]
) { ) {
pref = osID + ":" + preference; pref = osID + ":" + preference;
} else if ( } else if (
softwarePackages[currentPkgRef][ softwarePackages[packageKey][
"_" + currentSelector + ":" + osType + ":" + preference "_" + currentSelector + ":" + osType + ":" + preference
] ]
) { ) {
@ -235,15 +214,11 @@ async function generateInstallOrders() {
} catch (e) { } catch (e) {
let pref; let pref;
if ( if (
softwarePackages[currentPkgRef][ softwarePackages[packageKey]["_" + currentSelector + ":" + osID]
"_" + currentSelector + ":" + osID
]
) { ) {
pref = osID; pref = osID;
} else if ( } else if (
softwarePackages[currentPkgRef][ softwarePackages[packageKey]["_" + currentSelector + ":" + osType]
"_" + currentSelector + ":" + osType
]
) { ) {
pref = osType; pref = osType;
} }
@ -255,7 +230,6 @@ async function generateInstallOrders() {
continue pkgFor; continue pkgFor;
} }
} else if (normalCheck) { } else if (normalCheck) {
console.log('NORMAL CHECK')
try { try {
await $(normalCheck); await $(normalCheck);
} catch (e) { } catch (e) {
@ -271,67 +245,50 @@ async function generateInstallOrders() {
// Handle the _bin attribute // Handle the _bin attribute
currentSelector = "bin"; currentSelector = "bin";
doubleScoped = doubleScoped =
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference + ":" + osID "_" + currentSelector + ":" + preference + ":" + osID
]) || ] ||
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osID + ":" + preference "_" + currentSelector + ":" + osID + ":" + preference
]) || ] ||
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference + ":" + osType "_" + currentSelector + ":" + preference + ":" + osType
]) || ] ||
(softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osType + ":" + preference "_" + currentSelector + ":" + osType + ":" + preference
]); ];
scopedPkgManager = scopedPkgManager =
softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference "_" + currentSelector + ":" + preference
]; ];
scopedSystem = scopedSystem =
(softwarePackages[currentPkgRef] && softwarePackages[packageKey]["_" + currentSelector + ":" + osID] ||
softwarePackages[currentPkgRef][ softwarePackages[packageKey]["_" + currentSelector + ":" + osType];
"_" + currentSelector + ":" + osID normalCheck = softwarePackages[packageKey]["_" + currentSelector];
]) ||
(softwarePackages[currentPkgRef] &&
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osType
]);
normalCheck =
softwarePackages[currentPkgRef] &&
softwarePackages[currentPkgRef]["_" + currentSelector];
if (doubleScoped) { if (doubleScoped) {
const bin = which.sync(doubleScoped, { nothrow: true }); const bin = which.sync(doubleScoped, { nothrow: true });
if (!bin) { if (!bin) {
let pref; let pref;
if ( if (
softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference + ":" + osID "_" + currentSelector + ":" + preference + ":" + osID
] ]
) { ) {
pref = preference + ":" + osID; pref = preference + ":" + osID;
} else if ( } else if (
softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + preference + ":" + osType "_" + currentSelector + ":" + preference + ":" + osType
] ]
) { ) {
pref = preference + ":" + osType; pref = preference + ":" + osType;
} else if ( } else if (
softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osID + ":" + preference "_" + currentSelector + ":" + osID + ":" + preference
] ]
) { ) {
pref = osID + ":" + preference; pref = osID + ":" + preference;
} else if ( } else if (
softwarePackages[currentPkgRef] && softwarePackages[packageKey][
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osType + ":" + preference "_" + currentSelector + ":" + osType + ":" + preference
] ]
) { ) {
@ -362,17 +319,11 @@ async function generateInstallOrders() {
if (!bin) { if (!bin) {
let pref; let pref;
if ( if (
softwarePackages[currentPkgRef] && softwarePackages[packageKey]["_" + currentSelector + ":" + osID]
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osID
]
) { ) {
pref = osID; pref = osID;
} else if ( } else if (
softwarePackages[currentPkgRef] && softwarePackages[packageKey]["_" + currentSelector + ":" + osType]
softwarePackages[currentPkgRef][
"_" + currentSelector + ":" + osType
]
) { ) {
pref = osType; pref = osType;
} }