Skip to content

Commit

Permalink
chore(build): Cleanup dist targets to be more ideomatic
Browse files Browse the repository at this point in the history
  • Loading branch information
alerque committed Oct 30, 2023
1 parent a14c919 commit 927a8d5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,6 @@ jobs:
- name: Build source package
run: |
make dist
- name: Build release notes
if: github.repository == 'sile-typesetter/casile' && startsWith(github.ref, 'refs/tags/v')
run: |
make casile-${{ env.VERSION}}.md
- name: Publish Release
uses: softprops/action-gh-release@v1
if: github.repository == 'sile-typesetter/casile' && startsWith(github.ref, 'refs/tags/v')
Expand Down
15 changes: 10 additions & 5 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,10 @@ CARGO_FEATURE_ARGS = --all-features
clean-embedded-assets:
[[ ! -e .git ]] || $(GIT) clean -dxf assets

dist-hook:
dist-hook: dist-hook-yarn

.PHONY: dist-hook-yarn
dist-hook-yarn:
$(YARN) install --production --frozen-lockfile --modules-folder "$(distdir)/node_modules"

install-data-hook:
Expand All @@ -128,6 +131,12 @@ node_modules: yarn.lock
yarn.lock: package.json
$(YARN) install

dist: casile-$(VERSION).md

casile-%.md: CHANGELOG.md
$(SED) -e '/\.\.\.v$*/,/\.\.\.v/!d' $< | \
$(SED) -e '1,3d;N;$$!P;$$!D;$$d' > $@

PHONY_DEVELOPER_TARGETS = lint luacheck checkmake ruff tagrelease release-preview release docker docker-dep-check docker-ghcr-to-hub docker-build-push
.PHONY: $(PHONY_DEVELOPER_TARGETS)

Expand Down Expand Up @@ -160,10 +169,6 @@ release-preview:

release: tagrelease

casile-%.md: CHANGELOG.md
$(SED) -e '/\.\.\.v$*/,/\.\.\.v/!d' $< | \
$(SED) -e '1,3d;N;$$!P;$$!D;$$d' > $@

export GHCR_REGISTRY ?= ghcr.io
export GHCR_REPO ?= sile-typesetter/$(TRANSFORMED_PACKAGE_NAME)

Expand Down

0 comments on commit 927a8d5

Please sign in to comment.