-
Notifications
You must be signed in to change notification settings - Fork 54
/
snapcraft.yaml
43 lines (41 loc) · 1.76 KB
/
snapcraft.yaml
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
name: git-machete
adopt-info: git-machete # just for adopting `version`
summary: git-machete is a versatile tool for organizing your git repo
# language=markdown
description: |
git machete is a versatile tool for organizing your git repo, including features like:
- Neat, customizable `git machete status` that shows what branches are in sync with their parent branch/remote tracking branch and which of them need to be rebased/merged/pulled/pushed
- Semi-automatic `git machete traverse` through the branches that helps you effortlessly rebase/merge and push/pull the branches you care for
- Automatic discovery of branch relations (`git machete discover`)
# This software is unlikely to be used outside of desktop machines.
# Let's limit the number of target architectures to reduce the build times.
architectures:
- amd64
- arm64
base: core22
# See https://forum.snapcraft.io/t/-/15566 for discussion on why classic confinement was necessary.
confinement: classic
grade: stable
icon: graphics/logo/png/256x256.png
license: MIT
parts:
git-machete:
plugin: python
source: .
# See https://github.com/canonical/rockcraft/issues/225#issuecomment-1597025315
stage-packages: [python3.10-minimal]
# We're setting the version via scriptlet rather than using `version: git`
# since only pushing commits to master (and not pushing tags) triggers Snapcraft builds.
# language=sh
override-build: |
PS4='$0.$LINENO:'
set -x
craftctl default
version=$(cut -d\' -f2 git_machete/__init__.py)
craftctl set version="$version"
apps:
git-machete:
command: bin/git-machete
# Workaround for https://github.com/VirtusLab/git-machete/issues/1150
environment:
PYTHONPATH: /snap/git-machete/x1/lib/python3.10/site-packages