-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: use correct regex for new series in all.sh (#158)
* the CLI now does not print "UNSPECIFED" in messages when starting a new series; it only prints "Starting new series" (see trunk-io/trunk#9721) * stop explicitly passing `--token` in the `check_all_mode: hold-the-line` path - the CLI now respects `TRUNK_TOKEN` and #142 removed the explicit passing in most paths, except for the ones in `all.sh`
- Loading branch information
Showing
6 changed files
with
204 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#!/bin/bash | ||
|
||
set -euo pipefail | ||
|
||
src_repo=$1 | ||
output_repo=$2 | ||
|
||
git config --global init.defaultBranch main | ||
|
||
## Set up repo in `src_repo` | ||
|
||
mkdir -p "${src_repo}" | ||
( | ||
cd "${src_repo}" | ||
|
||
git init | ||
|
||
git config user.name 'trunk-io/trunk-action action_tests.trunk_merge' | ||
git config user.email 'action_tests@trunk-action.trunk.io' | ||
|
||
echo "This is a README." >>readme.md | ||
git add . | ||
git commit --all --message 'First commit' | ||
|
||
echo "These are contribution guidelines." >>contributing.md | ||
git add . | ||
git commit --all --message 'Second commit' | ||
|
||
## Prepare a branch `feature-branch` | ||
|
||
git checkout -b feature-branch main^ | ||
|
||
echo "markdown file for merge test" >>merge-test.md | ||
git add . | ||
git commit --all --message 'add file for merge test setup' | ||
|
||
## Prepare a merge graph commit | ||
|
||
git checkout -b trunk-merge/of-feature-branch main | ||
|
||
git merge --no-ff --no-edit feature-branch | ||
|
||
## Go back to `main` | ||
|
||
git checkout main | ||
|
||
## Dump the state of the repo | ||
|
||
git log --graph --pretty=oneline trunk-merge/of-feature-branch | ||
) | ||
|
||
## Set up repo in `output_repo` | ||
|
||
git clone "${src_repo}" "${output_repo}" | ||
|
||
## Force mktemp to point at TMPDIR | ||
|
||
mkdir -p "${TMPDIR}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters