mirror of
https://github.com/indetectables-net/toolkit.git
synced 2026-10-28 19:40:47 +00:00
Changes in pipeline
This commit is contained in:
1 parent
8ebadfb00b
commit
05b996f362
3 files changed
+14
-8
No files matched your search
@@ -73,12 +73,14 @@ jobs:
|
||||
working-directory: ${{ env.INSTALLER_SCRIPT_PATH }}
|
||||
run: |
|
||||
Set-ExecutionPolicy Bypass -Scope Process -Force
|
||||
.\generate-checksums.ps1 -Directory "${{ env.SRC_PATH }}/toolkit" -OutputFile "${{ env.SRC_PATH }}/tools_checksums.txt"
|
||||
.\generate-checksums.ps1 -Directory "${{ env.SRC_PATH }}/toolkit" -OutputFile "${{ github.workspace }}/tools_checksums.txt"
|
||||
.\generate-checksums.ps1 -Directory "${{ github.workspace }}" -FilePattern "*.exe" -OutputFile "${{ github.workspace }}/installer_checksums.txt"
|
||||
|
||||
- name: Upload Setup as Artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: setup-installer-artifact
|
||||
path: |
|
||||
./*.exe
|
||||
${{ env.SRC_PATH }}/tools_checksums.txt
|
||||
${{ github.workspace }}/*.exe
|
||||
${{ github.workspace }}/tools_checksums.txt
|
||||
${{ github.workspace }}/installer_checksums.txt
|
||||
@@ -1,6 +1,7 @@
|
||||
param (
|
||||
[string]$Directory = ".",
|
||||
[string]$OutputFile = "checksums.txt"
|
||||
[string]$OutputFile = "checksums.txt",
|
||||
[string]$FilePattern = "*"
|
||||
)
|
||||
|
||||
# Initialize an array to store the hash results
|
||||
@@ -20,10 +21,13 @@ function Get-FileHashSHA256 {
|
||||
return [BitConverter]::ToString($hash) -replace "-", ""
|
||||
}
|
||||
|
||||
# Iterate over each file in the directory
|
||||
Get-ChildItem -Path $Directory -File -Recurse | ForEach-Object {
|
||||
# Get the full path of the directory
|
||||
$fullDirectoryPath = (Get-Item -Path $Directory).FullName
|
||||
|
||||
# Iterate over each file in the directory matching the pattern
|
||||
Get-ChildItem -Path $Directory -Filter $FilePattern -File -Recurse | ForEach-Object {
|
||||
$fileHash = Get-FileHashSHA256 -filePath $_.FullName
|
||||
$relativePath = $_.FullName.Substring((Get-Location).Path.Length + 1)
|
||||
$relativePath = $_.FullName.Substring($fullDirectoryPath.Length).TrimStart('\')
|
||||
$hashResults += "$fileHash .\$relativePath"
|
||||
}
|
||||
|
||||
|
||||
@@ -70,7 +70,7 @@ class UnpackProject:
|
||||
# Iterate sub folders
|
||||
for item in pathlib.Path(folder_path).iterdir():
|
||||
if item.is_dir():
|
||||
print(colorama.Fore.MAGENTA + f' [!] Iterate sub folder: "{item}"')
|
||||
#print(colorama.Fore.MAGENTA + f' [!] Iterate sub folder: "{item}"')
|
||||
self.iterate_tool(item)
|
||||
|
||||
def iterate_tool_unpack(self, file_path, folder_path):
|
||||
|
||||
Reference in new issue
Block a user