~patmaddox

Check-in [747f92173f]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:merge build-ports

- simplify branch merging (configure via a local file, rather than 100% automatic)
- build a scratch branch
- list and log branches
- push branches (the ones I track, or selective)

Timelines: family | ancestors | descendants | both | old-trunk
Files: files | file ages | folders
SHA3-256: 747f92173fc13efe7a093fd675c380543828f3bd055689341d712bbfc5d4f83d
User & Date: patmaddox 2023-07-29 12:06:43
Original Comment: merge build-ports
Context
2023-07-29
12:43
www: delete writing topics (moved to drafts branch) check-in: 6926c1b111 user: patmaddox tags: old-trunk
12:39
draft: fossil code management check-in: d05ddce0cf user: patmaddox tags: drafts
12:06
merge build-ports

- simplify branch merging (configure via a local file, rather than 100% automatic)
- build a scratch branch
- list and log branches
- push branches (the ones I track, or selective) check-in: 747f92173f user: patmaddox tags: old-trunk

12:05
ports: push the branches that I merge, or selective branches Closed-Leaf check-in: 4ef53b3b51 user: patmaddox tags: build-ports
02:30
ports: fix example poudriere pkg repo config; remove ports that are tracked by git
- it had the wrong path for scratch
- -100 priority ends up becoming something like 48599 priority, which has the opposite of desired effect
check-in: 62c6ff62d8 user: patmaddox tags: old-trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ports/Justfile.

38
39
40
41
42
43
44






45
46
47
48






49

50
51

52


53
54
55
56
57
58
59














port name: _ports-git
  ./lib/make-worktree.sh {{name}}

_ports-git:
  @./lib/checkout-ports.sh







pull: _ports-git
  @cd freebsd-ports.git/main && git pull --ff-only

push: _ports-git






  @cd freebsd-ports.git/main && git push --branches patmaddox


merge: _myports

  @./lib/merge.sh



_myports: _ports-git
  #!/bin/sh
  if [ ! -d freebsd-ports.git/patmaddox-ports ]; then
    cd freebsd-ports.git/main
    git worktree add ../patmaddox-ports
  fi




















>
>
>
>
>
>



|
>
>
>
>
>
>
|
>


>
|
>
>







>
>
>
>
>
>
>
>
>
>
>
>
>
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88

port name: _ports-git
  ./lib/make-worktree.sh {{name}}

_ports-git:
  @./lib/checkout-ports.sh

branches: _ports-git
  cd freebsd-ports.git/main && git branch

log branch *args: _ports-git
  cd freebsd-ports.git/{{branch}} && git log {{args}}

pull: _ports-git
  @cd freebsd-ports.git/main && git pull --ff-only

push *branches: _ports-git
  #!/bin/sh
  if [ -z "{{branches}}" ]; then
    branches="patmaddox-ports $(cat merge-branches)"
  else
    branches="{{branches}}"
  fi
  cd freebsd-ports.git/main
  git push --atomic patmaddox $branches

merge: _myports
  #!/bin/sh
  branches=$(cat merge-branches)
  cd freebsd-ports.git/patmaddox-ports
  git merge --no-ff --no-edit $branches

_myports: _ports-git
  #!/bin/sh
  if [ ! -d freebsd-ports.git/patmaddox-ports ]; then
    cd freebsd-ports.git/main
    git worktree add ../patmaddox-ports
  fi

scratch +branches: _scratch
  #!/bin/sh
  cd freebsd-ports.git/scratch
  git reset --hard main
  git merge --no-ff --no-edit {{branches}}

_scratch: _ports-git
  #!/bin/sh
  if [ ! -d freebsd-ports.git/scratch ]; then
    cd freebsd-ports.git/main
    git worktree add ../scratch
  fi

Deleted ports/lib/merge.sh.

1
2
3
4
#!/bin/sh
cd freebsd-ports.git/patmaddox-ports
branches=$(git branch --format '%(refname:short)' | grep -v '^main$' | grep -v '^patmaddox-ports$' | grep -v '^scratch$)
git merge main $branches --no-ff --no-edit
<
<
<
<








Added ports/merge-branches.







>
>
>
1
2
3
main
lang-elixir-mode.el
ports-mgmt-poudriere-devel