Skip to content

Commit 7a78fae

Browse files
committed
Merge branch 'master' into 2023/day02
2 parents 6cee8ed + 639a395 commit 7a78fae

File tree

3 files changed

+22
-1
lines changed

3 files changed

+22
-1
lines changed

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,5 +157,9 @@ new-version: vet test-regression build
157157
open-advent-homepage:
158158
./scripts/browser-opener.sh -u 'https://adventofcode.com/'
159159

160+
gen-boilerplate:
161+
./scripts/codegen/puzzle-boilerplate.sh
162+
.PHONY: gen-boilerplate
163+
160164
.DEFAULT_GOAL := help
161165

internal/puzzles/solutions/new.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import (
1212

1313
func createNewFromTemplate(purl string) error {
1414
const (
15-
perms = 0o766
15+
perms = 0o655
1616
yearLen = 4
1717
dayLen = 2
1818
)
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/bin/bash
2+
3+
set -Eeuo pipefail
4+
5+
SCRIPT_NAME="$(basename "$0")"
6+
SCRIPT_DIR="$(dirname "$0")"
7+
REPO_ROOT="$(cd "${SCRIPT_DIR}" && git rev-parse --show-toplevel)"
8+
SCRIPTS_DIR="${REPO_ROOT}/scripts"
9+
10+
source "${SCRIPTS_DIR}/helpers-source.sh"
11+
12+
cd ${REPO_ROOT}/internal/puzzles/solutions || exit 1
13+
14+
go test -v -run Test_createNewFromTemplate
15+
16+
echo "${SCRIPT_NAME} done."
17+

0 commit comments

Comments
 (0)