Skip to content

Commit d5b0de8

Browse files
authored
Merge pull request #2 from OmegaRelay/develop
Release 0.1.2
2 parents 896e7c7 + d318a4e commit d5b0de8

File tree

5 files changed

+20
-13
lines changed

5 files changed

+20
-13
lines changed

.github/workflows/ci-main.yml renamed to .github/workflows/ci-pr-main.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
name: build
22

33
on:
4-
push:
5-
branches: [ "main" ]
6-
4+
pull_request:
5+
paths:
6+
- '**.go'
7+
- 'go.*'
8+
branches:
9+
- "main"
710

811
jobs:
912
build-macos-arm64:

.github/workflows/go-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Set up Go
2323
uses: actions/setup-go@v4
2424
with:
25-
go-version: '1.20'
25+
go-version: '1.23'
2626

2727
- name: Build
2828
run: go build -o ${GOOS}-${GOARCH}/

CHANGELOG.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [unreleased]
99

10+
## [0.1.2] - 2025-08-23
11+
12+
### Fixed
13+
- Set Github build actions to run on pull request into main
14+
- Update github build action's go version to 1.23
15+
- Remove unused error return value
16+
1017
## [0.1.1] - 2025-08-23
1118

1219
### Changed
@@ -39,7 +46,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3946
### Added
4047
- Copying embedded template directory
4148

42-
[unreleased]: https://github.com/OmegaRelay/west-project-init/compare/v0.1.1...develop
49+
[unreleased]: https://github.com/OmegaRelay/west-project-init/compare/v0.1.2...develop
50+
[0.1.2]: https://github.com/OmegaRelay/west-project-init/releases/tag/v0.1.2
4351
[0.1.1]: https://github.com/OmegaRelay/west-project-init/releases/tag/v0.1.1
4452
[0.1.0]: https://github.com/OmegaRelay/west-project-init/releases/tag/v0.1.0
4553
[0.0.2]: https://github.com/OmegaRelay/west-project-init/releases/tag/v0.0.2

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.1.1
1+
0.1.2

main.go

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -158,10 +158,7 @@ func copyTemplateContents(path string, entries []fs.DirEntry) {
158158
if err != nil {
159159
panic(err)
160160
}
161-
content, err = replaceKeyWords(content)
162-
if err != nil {
163-
panic(err)
164-
}
161+
content = replaceKeyWords(content)
165162
err = os.WriteFile(entryPath, content, touchPerms)
166163
if err != nil {
167164
panic(err)
@@ -171,7 +168,7 @@ func copyTemplateContents(path string, entries []fs.DirEntry) {
171168
}
172169

173170
// Keywords within @@ symbols are replaced with dynamic components
174-
func replaceKeyWords(b []byte) (ret []byte, err error) {
171+
func replaceKeyWords(b []byte) []byte {
175172
array := bytes.Split(b, []byte("@"))
176173

177174
for index, val := range array {
@@ -185,8 +182,7 @@ func replaceKeyWords(b []byte) (ret []byte, err error) {
185182
continue
186183
}
187184
}
188-
ret = bytes.Join(array, nil)
189-
return
185+
return bytes.Join(array, nil)
190186
}
191187

192188
// Wrapper around exec.Command to start, attach and print output of the command

0 commit comments

Comments
 (0)