Skip to content
This repository was archived by the owner on Nov 2, 2021. It is now read-only.

Commit 4dea6bd

Browse files
committed
read username from template
Signed-off-by: MarcoIeni <11428655+MarcoIeni@users.noreply.github.com>
1 parent 69f604b commit 4dea6bd

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

.github/workflows/example-sync.yaml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,7 @@ jobs:
1818

1919
- name: Create new example
2020
run: |
21-
cargo generate --git https://github.com/rust-github/template.git --name rust-gh-example
22-
23-
- name: replace username
24-
run: |
25-
cd rust-gh-example
26-
sed -i 's#{\[username\]}#rust-github#g' $(find . -type f -name '*.md' -o -name '*.yml' -o -name '*.toml')
21+
cargo generate --git https://github.com/rust-github/template.git --name rust-gh-example --template-values-file template_values.toml
2722
2823
- name: Checkout old example
2924
uses: actions/checkout@v2

template_values.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[values]
2+
username = "rust-github"

0 commit comments

Comments
 (0)