-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcreate_windows_package.sh
More file actions
executable file
·92 lines (75 loc) · 2.72 KB
/
create_windows_package.sh
File metadata and controls
executable file
·92 lines (75 loc) · 2.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#!/bin/bash
# create_windows_package.sh
# Script to create a Windows package for Axon with a placeholder
# Set version
VERSION="1.0.0"
# Create directory for Windows package
echo "Creating Windows package directory..."
mkdir -p axon-win
# We know you don't have build-win/axon.exe, so we'll create the placeholder
echo "Creating placeholder README..."
echo "This is a placeholder file. Please build the real executable on Windows." > axon-win/README.txt
# Copy documentation files
echo "Copying documentation files..."
cp README.md axon-win/ 2>/dev/null || echo "Warning: Could not copy README.md"
cp LICENSE axon-win/ 2>/dev/null || echo "Warning: Could not copy LICENSE"
# Create installation instructions
echo "Creating installation instructions..."
cat > axon-win/INSTALL.txt << 'EOF'
AXON ENCRYPTION TOOL - WINDOWS INSTALLATION
When you have built the axon.exe executable:
1. Copy axon.exe to a permanent location (e.g., C:\Program Files\Axon)
2. Add that location to your PATH environment variable:
- Right-click on 'This PC' and select 'Properties'
- Click on 'Advanced system settings'
- Click on 'Environment Variables'
- Under 'System variables', select 'Path' and click 'Edit'
- Click 'New' and add the path to the Axon directory
- Click 'OK' on all dialogs
3. Open a new command prompt and type 'axon' to verify installation
EOF
# Create a batch installer
echo "Creating batch installer..."
cat > axon-win/install.bat << 'EOF'
@echo off
echo Axon Windows Installer
echo ---------------------
echo.
:: Check if axon.exe exists in the current directory
if not exist "axon.exe" (
echo ERROR: axon.exe not found!
echo This package contains only a placeholder.
echo You need to build the actual executable for Windows first.
echo.
echo Please see README.txt for more information.
pause
exit /b 1
)
:: Create Program Files directory
echo Creating installation directory...
if not exist "%ProgramFiles%\Axon" mkdir "%ProgramFiles%\Axon"
:: Copy executable
echo Copying executable...
copy /Y "axon.exe" "%ProgramFiles%\Axon\"
:: Add to PATH (requires admin privileges)
echo Adding to PATH...
setx /M PATH "%PATH%;%ProgramFiles%\Axon"
echo.
echo Installation complete!
echo You may need to restart your command prompt for the PATH changes to take effect.
pause
EOF
# Create a ZIP file
echo "Creating Windows package ZIP file..."
if command -v zip >/dev/null 2>&1; then
zip -r axon-${VERSION}-win.zip axon-win
echo "Created: axon-${VERSION}-win.zip"
else
# Fallback if zip is not available
tar -czvf axon-${VERSION}-win.tar.gz axon-win
echo "Created: axon-${VERSION}-win.tar.gz"
fi
# Clean up
echo "Cleaning up temporary files..."
rm -rf axon-win
echo "Windows package creation completed successfully."