mirror of
https://github.com/KaySar12/NextZen-UserService.git
synced 2025-03-15 15:15:35 +07:00
update: Makefile
This commit is contained in:
parent
fc915ebda5
commit
24369c69fa
@ -145,9 +145,9 @@ archives:
|
||||
- name_template: >-
|
||||
{{ .Os }}-{{- if eq .Arch "arm" }}arm-7{{- else }}{{ .Arch }}{{- end }}-{{ .ProjectName }}-v{{ .Version }}
|
||||
builds:
|
||||
- casaos-user-service-amd64
|
||||
- casaos-user-service-arm64
|
||||
- casaos-user-service-arm-7
|
||||
- nextzen-user-service-amd64
|
||||
- nextzen-user-service-arm64
|
||||
- nextzen-user-service-arm-7
|
||||
files:
|
||||
- build/**/*
|
||||
# - name_template: >-
|
||||
@ -169,11 +169,12 @@ changelog:
|
||||
exclude:
|
||||
- "^docs:"
|
||||
- "^test:"
|
||||
- "^update:"
|
||||
release:
|
||||
github:
|
||||
owner: KaySar12
|
||||
name: NextZen-UserService
|
||||
owner: IceWhaleTech
|
||||
name: CasaOS-UserService
|
||||
draft: true
|
||||
prerelease: auto
|
||||
mode: replace
|
||||
name_template: "v{{ .Version }}"
|
||||
name_template: "v{{ .Version }}"
|
15
Makefile
15
Makefile
@ -9,12 +9,11 @@ VERSION=v1
|
||||
BIN_PATH=build/sysroot/usr/bin
|
||||
BUILD_PATH=build
|
||||
CUR_DIR=$(PWD)
|
||||
CUR_TAG ?= $(shell git describe --tags --match '*.*.*' | sort -V | tail -n1)
|
||||
PREV_TAG ?= $(shell git describe --tags --match '*.*.*' | sort -V | head -n2 | tail -n1)
|
||||
CUR_TAG ?= $(shell git describe --tags --match '*.*.*' | sort -V | tail -n1 | sed 's/-[0-9]*-g[0-9a-f]*//')
|
||||
PREV_TAG ?= $(shell git describe --tags --match '*.*.*' | sort -V | head -n2 | tail -n1 | sed 's/-[0-9]*-g[0-9a-f]*//')
|
||||
ARCHIVE_PATH=buildzip
|
||||
PACKAGE_NAME=$(OS)-$(ARCHITECHTURE)-nextzenos-user-service-$(TAG)
|
||||
|
||||
GIT_COMMIT_MESSAGE ?="update"
|
||||
COMMIT_MESSAGE ?="update"
|
||||
build_service:
|
||||
$(GORELEASERBUILD) --clean --snapshot -f .goreleaser.debug.yaml --id $(SERVICE)-$(ARCHITECHTURE)
|
||||
|
||||
@ -30,7 +29,7 @@ remove_package:
|
||||
clear_archive:
|
||||
@rm -rf $(CUR_DIR)/$(ARCHIVE_PATH)
|
||||
#make create_tag CUR_TAG=x.x TAG_MESSAGE="this is tag message"
|
||||
create_tag:push_git
|
||||
create_tag:
|
||||
@${GIT} tag -a ${CUR_TAG} -m "${TAG_MESSAGE}" || { echo "Failed to create tag"; exit 1; }
|
||||
@${GIT} push ${GIT_REMOTE} ${CUR_TAG} || { echo "Failed to push tag"; exit 1; }
|
||||
#make remove_tag CUR_TAG=x.x
|
||||
@ -40,12 +39,12 @@ remove_tag:
|
||||
check_tag:
|
||||
@echo "Previous tag: $(PREV_TAG)";
|
||||
@echo "Current tag: $(CUR_TAG)";
|
||||
push_release_all:push_git
|
||||
push_release_all:
|
||||
${GORELEASER} release --clean -f .goreleaser.yaml
|
||||
push_release:push_git
|
||||
push_release:
|
||||
${GORELEASER} release --single-target
|
||||
push_git:
|
||||
@${GIT} pull ${GIT_REMOTE}
|
||||
@${GIT} add .
|
||||
@${GIT} commit -m "${GIT_COMMIT_MESSAGE}"
|
||||
@${GIT} commit -m "${COMMIT_MESSAGE}"
|
||||
@${GIT} push ${GIT_REMOTE}
|
Loading…
Reference in New Issue
Block a user