Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

+git3 #457

Open
wants to merge 10 commits into
base: main
Choose a base branch
from
Open

+git3 #457

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
49 changes: 49 additions & 0 deletions projects/git3.sh/package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
distributable:
url: https://github.com/git3protocol/git3-cli/archive/refs/tags/v{{version}}.tar.gz
strip-components: 1

versions:
github: git3protocol/git3-cli
strip: /v/

dependencies:
nodejs.org: ^18

build:
dependencies:
classic.yarnpkg.com: '*'
stedolan.github.io/jq: '*'
script: |
mkdir -p {{prefix}}/bin

# patch git3.pkg.json to add:
# - node18-macos-arm64
# - node18-linux-arm64
jq \
'.pkg.targets[3] |= . + "node18-macos-arm64" | .pkg.targets[4] |= . + "node18-linux-arm64"' \
git3.pkg.json > git3.pkg.json.tmp
mv git3.pkg.json.tmp git3.pkg.json
ARCH=$(uname -m | sed -e 's/x86_64/x64/' -e 's/aarch64/arm64/')
sed -i.bak \
-e 's|/usr/local/bin|{{prefix}}/bin|g' \
-e 's|wait|sleep 10|g' \
-e "s_bin/git3-macos _bin/git3-macos-${ARCH} _g" \
-e "s_bin/git3-linux _bin/git3-linux-${ARCH} _g" \
package.json
rm package.json.bak

yarn
yarn $INSTALL
env:
linux:
INSTALL: install-linux
darwin:
INSTALL: install-mac

provides:
- bin/git-remote-git3
- bin/git3

test: |
git3 --help
git3 wallet list
Loading