Skip to content

Commit 7cfb0ec

Browse files
v0.1.2 release improvements
1 parent 1218756 commit 7cfb0ec

File tree

4 files changed

+151
-50
lines changed

4 files changed

+151
-50
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,13 @@ If you are building it yourself, clone the repo and build the binary:
3030
```bash
3131
git clone https://github.com/robert-mcdermott/uve.git
3232
cd uve
33-
go build -ldflags="-s -w" -o uve-bin uve
33+
go build -ldflags="-s -w" -o uve-bin main.go
3434
```
3535

3636
### Installation from pre-built binary:
3737

38-
If you've rather just use a pre-built binary, download the binary archive for your platform (os and architecture) from the [releases page](https://github.com/robert-mcdermott/uve/releases)
39-
and extract the archive to a directory of your choice. Unless you have a reason to select a specific release, choose the latest release. After you have extracted the archive, open a shell in that folder and follow the instructions for your platform below:
38+
If you'd rather just use a pre-built binary, download the archive for your platform (OS and architecture) from the [releases page](https://github.com/robert-mcdermott/uve/releases)
39+
and extract the archive to a directory of your choice. Unless you have a reason to select a specific release, choose the latest release.
4040

4141
### Install the binary:
4242

@@ -68,13 +68,13 @@ Unblock-File -Path "$env:USERPROFILE\bin\uve-bin.exe"
6868

6969
### Set up shell integration:
7070

71-
UVE now includes automatic shell integration. Simply run:
71+
UVE includes automatic shell integration with all shell scripts embedded in the binary. Simply run:
7272

7373
```bash
7474
uve-bin init
7575
```
7676

77-
#### *Note: running 'uve-bin' should only be used for the inital shell integration when first installing uve, after shell integration is complete, you'll only use the 'uve' command for all other operations*
77+
#### *Note: running 'uve-bin' should only be used for the initial shell integration when first installing uve, after shell integration is complete, you'll only use the 'uve' command for all other operations*
7878

7979
This will:
8080
- Detect your shell type (bash, zsh, or PowerShell)

RELEASE_NOTES.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# UVE 0.1.2 Release Notes
2+
3+
## Overview
4+
5+
UVE 0.1.2 introduces significant improvements to the codebase structure and distribution process, making the tool more maintainable and easier to distribute. This release focuses on technical improvements while maintaining full compatibility with previous versions.
6+
7+
## What's New
8+
9+
- **New `init` Subcommand**: Added a new `uve-bin init` command that automatically detects your shell type and sets up the appropriate shell integration. No more manual copying of shell scripts!
10+
- **Automatic Shell Detection**: UVE now automatically detects whether you're using Bash, Zsh, or PowerShell and configures the appropriate integration.
11+
- **Simplified Setup Process**: The entire installation process is now just: download, place in PATH, run `uve-bin init`, and you're ready to go.
12+
- **Self-contained Binary**: Shell integration scripts are now embedded directly into the binary using Go's embed directive, eliminating the need for separate script files during installation.
13+
- **Simplified Installation**: The new "init" shell interation automatically creates the shell scripts and sets up shell integration for you.
14+
- **SHA256 Checksums**: Added SHA256 checksums for all distribution packages to enhance security.
15+
- **Improved Documentation**: Updated installation instructions to reflect the new self-contained binary approach.
16+
- **Mark of the Web Handling**: Added explicit instructions to unblock downloaded executables on Windows using `Unblock-File`.
17+
18+
19+
## Compatibility
20+
21+
UVE 0.1.2 is fully compatible with previous versions. No changes to existing environments or workflows are required.
22+
23+
## Installation
24+
25+
Download the appropriate package for your platform from the [releases page](https://github.com/robert-mcdermott/uve/releases/tag/v0.1.2), extract it, and follow the installation instructions in the README.
26+
27+
### Quick Installation Steps
28+
29+
1. Download and extract the appropriate package for your platform
30+
2. Copy the `uve-bin` executable to a directory in your PATH
31+
3. Run `uve-bin init` to set up shell integration
32+
4. Restart your shell or source your shell configuration file
33+
5. Start using UVE with the `uve` command!
34+
35+
## Supported Platforms
36+
37+
- Windows (x86_64)
38+
- macOS (Intel x86_64 and Apple Silicon ARM64)
39+
- Linux (x86_64)
40+
41+
## Known Issues
42+
43+
None at this time.
44+
45+
---
46+
47+
Thank you for using UVE! If you encounter any issues or have suggestions, please submit them on the [GitHub repository](https://github.com/robert-mcdermott/uve/issues).

build/compile-all.sh

Lines changed: 0 additions & 26 deletions
This file was deleted.

build/package-release.sh

Lines changed: 99 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,101 @@
11
#!/usr/bin/env bash
22

3-
mkdir -p dist/uve-0.1-linux-x86_64
4-
cp uve-linux-amd64 dist/uve-0.1-linux-x86_64/uve-bin
5-
cp uve.sh dist/uve-0.1-linux-x86_64/uve.sh
6-
tar -zcvf dist/uve-0.1-linux-x86_64.tgz dist/uve-0.1-linux-x86_64
7-
8-
mkdir -p dist/uve-0.1-macos-arm64
9-
cp uve-darwin-arm64 dist/uve-0.1-macos-arm64/uve-bin
10-
cp uve.sh dist/uve-0.1-macos-arm64/uve.sh
11-
tar -zcvf dist/uve-0.1-macos-arm64.tgz dist/uve-0.1-macos-arm64
12-
13-
mkdir -p dist/uve-0.1-macos-x86_64
14-
cp uve-darwin-amd64 dist/uve-0.1-macos-x86_64/uve-bin
15-
cp uve.sh dist/uve-0.1-macos-x86_64/uve.sh
16-
tar -zcvf dist/uve-0.1-macos-x86_64.tgz dist/uve-0.1-macos-x86_64
17-
18-
mkdir -p dist/uve-0.1-windows-x86_64
19-
cp uve-windows-amd64.exe dist/uve-0.1-windows-x86_64/uve-bin.exe
20-
cp uve.ps1 dist/uve-0.1-windows-x86_64/uve.ps1
21-
zip -r -X dist/uve-0.1-windows-x86_64.zip dist/uve-0.1-windows-x86_64
3+
# Configuration
4+
VERSION="0.1.2"
5+
PACKAGE="main.go"
6+
BINARY_NAME="uve-bin"
7+
PLATFORMS=("windows/amd64" "linux/amd64" "darwin/amd64" "darwin/arm64")
8+
9+
# Ensure we're in the project root directory
10+
cd "$(dirname "$0")/.." || exit 1
11+
12+
echo "=== Building UVE v${VERSION} ==="
13+
14+
# Compile for all platforms
15+
for platform in "${PLATFORMS[@]}"
16+
do
17+
platform_split=(${platform//\// })
18+
GOOS=${platform_split[0]}
19+
GOARCH=${platform_split[1]}
20+
21+
# Set output filename based on platform
22+
if [ "$GOOS" = "windows" ]; then
23+
output_name="${BINARY_NAME}-${GOOS}-${GOARCH}.exe"
24+
else
25+
output_name="${BINARY_NAME}-${GOOS}-${GOARCH}"
26+
fi
27+
28+
echo "Building for $GOOS/$GOARCH..."
29+
env GOOS=$GOOS GOARCH=$GOARCH go build -ldflags="-s -w" -o $output_name $PACKAGE
30+
31+
if [ $? -ne 0 ]; then
32+
echo "Error building for $GOOS/$GOARCH"
33+
exit 1
34+
fi
35+
done
36+
37+
echo "=== Creating release packages ==="
38+
39+
# Create a temporary README.txt with installation instructions
40+
cat > README.txt << 'EOL'
41+
UVE - UV Environment Manager
42+
43+
INSTALLATION:
44+
45+
Linux/macOS:
46+
1. Copy uve-bin to a directory in your PATH (e.g., ~/bin/)
47+
2. Run: uve-bin init
48+
3. Restart your shell or source your shell config file
49+
50+
Windows:
51+
1. Copy uve-bin.exe to a directory in your PATH (e.g., %USERPROFILE%\bin\)
52+
2. Run: uve-bin.exe init
53+
3. Start a new PowerShell session or run: Import-Module uve
54+
55+
For full documentation, visit: https://github.com/robert-mcdermott/uve
56+
EOL
57+
58+
# Create distribution directories
59+
mkdir -p dist
60+
61+
# Linux x86_64
62+
mkdir -p tmp/uve-${VERSION}-linux-x86_64
63+
cp ${BINARY_NAME}-linux-amd64 tmp/uve-${VERSION}-linux-x86_64/${BINARY_NAME}
64+
cp README.txt tmp/uve-${VERSION}-linux-x86_64/
65+
cp LICENSE tmp/uve-${VERSION}-linux-x86_64/
66+
tar -zcvf dist/uve-${VERSION}-linux-x86_64.tar.gz -C tmp uve-${VERSION}-linux-x86_64
67+
68+
# macOS ARM64
69+
mkdir -p tmp/uve-${VERSION}-macos-arm64
70+
cp ${BINARY_NAME}-darwin-arm64 tmp/uve-${VERSION}-macos-arm64/${BINARY_NAME}
71+
cp README.txt tmp/uve-${VERSION}-macos-arm64/
72+
cp LICENSE tmp/uve-${VERSION}-macos-arm64/
73+
tar -zcvf dist/uve-${VERSION}-macos-arm64.tar.gz -C tmp uve-${VERSION}-macos-arm64
74+
75+
# macOS x86_64
76+
mkdir -p tmp/uve-${VERSION}-macos-x86_64
77+
cp ${BINARY_NAME}-darwin-amd64 tmp/uve-${VERSION}-macos-x86_64/${BINARY_NAME}
78+
cp README.txt tmp/uve-${VERSION}-macos-x86_64/
79+
cp LICENSE tmp/uve-${VERSION}-macos-x86_64/
80+
tar -zcvf dist/uve-${VERSION}-macos-x86_64.tar.gz -C tmp uve-${VERSION}-macos-x86_64
81+
82+
# Windows x86_64
83+
mkdir -p tmp/uve-${VERSION}-windows-x86_64
84+
cp ${BINARY_NAME}-windows-amd64.exe tmp/uve-${VERSION}-windows-x86_64/${BINARY_NAME}.exe
85+
cp README.txt tmp/uve-${VERSION}-windows-x86_64/
86+
cp LICENSE tmp/uve-${VERSION}-windows-x86_64/
87+
(cd tmp && zip -r -X ../dist/uve-${VERSION}-windows-x86_64.zip uve-${VERSION}-windows-x86_64)
88+
89+
# Generate checksums
90+
cd dist
91+
sha256sum *.tar.gz *.zip > SHA256SUMS.txt
92+
cd ..
93+
94+
# Clean up
95+
rm -rf tmp
96+
rm README.txt
97+
rm ${BINARY_NAME}-*
98+
99+
echo "=== Release packages created in dist/ directory ==="
100+
echo "Version: ${VERSION}"
101+
echo "Platforms: ${PLATFORMS[*]}"

0 commit comments

Comments
 (0)