Skip to content

Commit

Permalink
Merge pull request #405 from vdye/387-add-ui-and-symlink-deb
Browse files Browse the repository at this point in the history
Add UI helpers to .deb package & change install location w/ symlinking
  • Loading branch information
mjcheetham authored Aug 17, 2021
2 parents 838bbff + 6b6b08b commit 8676ca5
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions src/linux/Packaging.Linux/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,9 @@ tar -czvf "$SYMTARBALL" * || exit 1
popd

# Build .deb
INSTALL_TO="$DEBROOT/usr/bin/"
mkdir -p "$DEBROOT/DEBIAN" "$INSTALL_TO" || exit 1
INSTALL_TO="$DEBROOT/usr/local/share/gcm-core/"
LINK_TO="$DEBROOT/usr/local/bin/"
mkdir -p "$DEBROOT/DEBIAN" "$INSTALL_TO" "$LINK_TO" || exit 1

# make the debian control file
cat >"$DEBROOT/DEBIAN/control" <<EOF
Expand All @@ -167,13 +168,23 @@ Architecture: $ARCH
Depends:
Maintainer: GCM-Core <[email protected]>
Description: Cross Platform Git Credential Manager Core command line utility.
GCM Core supports authentication with a number of Git hosting providers
including GitHub, BitBucket, and Azure DevOps.
GCM Core supports authentication with a number of Git hosting providers
including GitHub, BitBucket, and Azure DevOps.
For more information see https://aka.ms/gcmcore
EOF

# Copy single binary to target installation location
# Copy GCM Core & UI helper binaries to target installation location
cp "$PAYLOAD/git-credential-manager-core" "$INSTALL_TO" || exit 1
cp "$PAYLOAD/Atlassian.Bitbucket.UI" "$INSTALL_TO" || exit 1
cp "$PAYLOAD/GitHub.UI" "$INSTALL_TO" || exit 1

# Create symlinks
ln -s -r "$INSTALL_TO/git-credential-manager-core" \
"$LINK_TO/git-credential-manager-core" || exit 1
ln -s -r "$INSTALL_TO/Atlassian.Bitbucket.UI" \
"$LINK_TO/Atlassian.Bitbucket.UI" || exit 1
ln -s -r "$INSTALL_TO/GitHub.UI" \
"$LINK_TO/GitHub.UI" || exit 1

dpkg-deb --build "$DEBROOT" "$DEBPKG" || exit 1

Expand Down

0 comments on commit 8676ca5

Please sign in to comment.