Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ source ~/.zshrc

### NPM Install
```bash
npm install -g go-blueprint
npm install -g @melkeydev/go-blueprint
```

### Homebrew Install
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ This command installs the Go-Blueprint binary, automatically binding it to your
If you prefer using Node.js package manager, you can install Go-Blueprint via NPM. This method is convenient for developers who are already working in JavaScript/Node.js environments and want to integrate Go-Blueprint into their existing workflow.

```bash
npm install -g go-blueprint
npm install -g @melkeydev/go-blueprint
```

The `-g` flag installs Go-Blueprint globally, making it accessible from any directory on your system.
Expand Down
9 changes: 5 additions & 4 deletions scripts/create-npm-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
set -euo pipefail

VERSION="$1"
PACKAGE_NAME="go-blueprint"
PACKAGE_NAME="@melkeydev/go-blueprint"
MAIN_PACKAGE_DIR="npm-package"
PLATFORM_PACKAGES_DIR="platform-packages"

Expand Down Expand Up @@ -55,7 +55,7 @@ for archive in dist/*.tar.gz dist/*.zip; do

echo " Creating package for platform: $platform_key"

platform_package_dir="$PLATFORM_PACKAGES_DIR/$PACKAGE_NAME-$platform_key"
platform_package_dir="$PLATFORM_PACKAGES_DIR/go-blueprint-$platform_key"
mkdir -p "$platform_package_dir/bin"

if [[ "$archive" == *.tar.gz ]]; then
Expand Down Expand Up @@ -122,7 +122,7 @@ cat > "$MAIN_PACKAGE_DIR/bin/go-blueprint" << 'EOF'
const { execFileSync } = require('child_process')
const packageName = 'go-blueprint'
const packageName = '@melkeydev/go-blueprint'
const platformPackages = {
'darwin-x64': `${packageName}-darwin-x64`,
Expand All @@ -144,6 +144,7 @@ function getBinaryPath() {
try {
const binaryName = process.platform === 'win32' ? 'go-blueprint.exe' : 'go-blueprint'
const packagePath = platformPackageName.replace('@', '').replace('/', '-')
return require.resolve(`${platformPackageName}/bin/${binaryName}`)
} catch (e) {
process.exit(1)
Expand Down Expand Up @@ -198,7 +199,7 @@ const path = require('path')
const binaryName = process.platform === 'win32' ? 'go-blueprint.exe' : 'go-blueprint'
const packageName = 'go-blueprint'
const packageName = '@melkeydev/go-blueprint'
const platformPackages = {
'darwin-x64': `${packageName}-darwin-x64`,
Expand Down