File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4545cabal_files=$( fd -ae ' cabal' )
4646for cf in $cabal_files ; do
4747 name=$( cat $cf | grep ' ^name:' | awk ' { print $2 }' )
48- if [[ -d " $CHAP_DIR /_sources/ $name " ]] ; then
49- version= $( ls -1 $CHAP_DIR /_sources/$name | sort -V | tail -1 )
48+ version= $( cat $cf | grep ' ^version: ' | awk ' { print $2 } ' )
49+ if [[ -d " $CHAP_DIR /_sources/$name / $version " ]] ; then
5050 rev=$( yq .github.rev $CHAP_DIR /_sources/$name /$version /meta.toml)
5151 git restore --source=$rev -- $name
5252 tb=0
@@ -57,7 +57,7 @@ for cf in $cabal_files; do
5757 cp $revdir /$rev " $name /$name .cabal"
5858 fi
5959 else
60- echo " WARNING: $name not in cardano-haskell-packages"
60+ echo " WARNING: $name - $version not in cardano-haskell-packages"
6161 fi
6262done
6363
8282
8383pushd $CHAP_DIR
8484if [[ $TEST == 0 && $( git symbolic-ref --short HEAD) =~ ^dmq-node\/ release- ]] then
85- gh pr comment --body " * [x] checked with \` build-with-chap.sh\` in \` dmq-network \ `"
85+ gh pr comment --body " * [x] checked with \` build-with-chap.sh\` in \` dmq-node ` "
8686fi
Original file line number Diff line number Diff line change 8181 git switch main
8282 git pull
8383 fi
84- BRANCH=" dmq-node/release-$( date -I ) "
84+ BRANCH=" dmq-node/release-$( date +%Y%m%d-%H%m%S ) "
8585 if [[ $TEST == 1 ]]; then
8686 BRANCH=" ${BRANCH} -DO_NOT_MERGE"
8787 fi
8888 git switch -c $BRANCH
8989
90+ # Gather packages to publish on CHaP
91+ publish=" "
9092 for cf in $cabal_files ; do
9193 name=$( cat $cf | grep ' ^name:' | awk ' { print $2 }' )
9294 version=$( cat $cf | grep ' ^version:' | awk ' { print $2 }' )
9395 dir=" $CHAP_DIR /_sources/$name /$version "
9496 if [[ ! (-d $dir ) ]]; then
95- trace " publishing $name -$version "
96- ./scripts/add-from-github.sh $REPO_URL $gitsha $name
97+ publish=" $publish $name "
9798 if [[ $TEST == 0 ]]; then
9899 git --git-dir " $gitdir /.git" tag " $name -$version " $gitsha
99100 fi
100101 fi
101102 done
103+ trace " Publishing:$publish "
104+ ./scripts/add-from-github.sh $REPO_URL $gitsha $publish
102105
103106 git --no-pager log --oneline origin/main..HEAD
104107
You can’t perform that action at this time.
0 commit comments