Skip to content
Snippets Groups Projects
Verified Commit 9aeb0c55 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

fix: test gorelease

parent dcd7d37e
No related branches found
No related tags found
No related merge requests found
...@@ -226,21 +226,20 @@ builds: ...@@ -226,21 +226,20 @@ builds:
scripts.tag-version.exec = '' scripts.tag-version.exec = ''
!#${pkgs.bash}/bin/bash !#${pkgs.bash}/bin/bash
set -x
${pkgs.git}/bin/git config user.email "''${GITLAB_USER_EMAIL}" ;\ ${pkgs.git}/bin/git config user.email "''${GITLAB_USER_EMAIL}"
${pkgs.git}/bin/git config user.name "''${GITLAB_USER_NAME:-"Gitlab CI"}" ;\ ${pkgs.git}/bin/git config user.name "''${GITLAB_USER_NAME:-"Gitlab CI"}"
${pkgs.git}/bin/git config credential.helper '!f() { echo "username=gitlab-ci-token"; echo "password=''${CI_JOB_TOKEN}"; }; f' ;\ ${pkgs.git}/bin/git config credential.helper '!f() { echo "username=gitlab-ci-token"; echo "password=''${CI_JOB_TOKEN}"; }; f'
${pkgs.git}/bin/git config pull.rebase true ;\ ${pkgs.git}/bin/git config pull.rebase true
${pkgs.git}/bin/git config http.sslVerify "false" ;\ ${pkgs.git}/bin/git config http.sslVerify "false"
${pkgs.git}/bin/git remote set-url origin https://pad:''${GITLAB_TOKEN}@''${CI_REPOSITORY_URL#*@} ;\ ${pkgs.git}/bin/git remote set-url origin https://pad:''${GITLAB_TOKEN}@''${CI_REPOSITORY_URL#*@}
${pkgs.git}/bin/git fetch --all --tags --unshallow ;\ ${pkgs.git}/bin/git fetch --all --tags --unshallow
${pkgs.git}/bin/git reset --hard origin/master ;\ ${pkgs.git}/bin/git reset --hard origin/master
${pkgs.git}/bin/git checkout $CI_COMMIT_REF_NAME ;\ ${pkgs.git}/bin/git checkout $CI_COMMIT_REF_NAME
${pkgs.git}/bin/git pull origin $CI_COMMIT_REF_NAME ;\ ${pkgs.git}/bin/git pull origin $CI_COMMIT_REF_NAME
${inputs.version.defaultPackage."${builtins.currentSystem}"}/bin/version auto --git --verbose ;\ ${inputs.version.defaultPackage."${builtins.currentSystem}"}/bin/version auto --git --verbose
${pkgs.git}/bin/git push origin $CI_COMMIT_REF_NAME ${pkgs.git}/bin/git push origin $CI_COMMIT_REF_NAME
''; '';
scripts.update-files.exec = '' scripts.update-files.exec = ''
!#${pkgs.bash}/bin/bash !#${pkgs.bash}/bin/bash
...@@ -269,7 +268,6 @@ builds: ...@@ -269,7 +268,6 @@ builds:
cat ${gitlabCiYaml} > "${config.devenv.root}/.gitlab-ci.yml" cat ${gitlabCiYaml} > "${config.devenv.root}/.gitlab-ci.yml"
''; '';
...@@ -281,50 +279,57 @@ builds: ...@@ -281,50 +279,57 @@ builds:
difftastic.enable = true; difftastic.enable = true;
# This script is executed when the app is built
# You can use it to build the app
scripts.build-app.exec = '' scripts.build-app.exec = ''
#!${pkgs.bash}/bin/bash #!${pkgs.bash}/bin/bash
set -x ${pkgs.nix}/bin/nix build .#version
PATH="''${PATH}":${pkgs.coreutils}/bin '';
PATH="''${PATH}":${pkgs.findutils}/bin
PATH="''${PATH}":${pkgs.jq}/bin/ # # This script is executed when the app is built
PATH="''${PATH}":${pkgs.rsync}/bin/ # # You can use it to build the app
PATH="''${PATH}":${pkgs.bash}/bin/ # scripts.build-app.exec = ''
PATH="''${PATH}":${pkgs.curl}/bin/ ##!${pkgs.bash}/bin/bash
PATH="''${PATH}":${pkgs.moreutils}/bin/ #
PATH="''${PATH}":${pkgs.gnutar}/bin #set -x
PATH="''${PATH}":${pkgs.gzip}/bin/ #
PATH="''${PATH}":${pkgs.procps}/bin/ #PATH="''${PATH}":${pkgs.coreutils}/bin
PATH="''${PATH}":${pkgs.eza}/bin/ #PATH="''${PATH}":${pkgs.findutils}/bin
PATH="''${PATH}":${pkgs.git}/bin/ #PATH="''${PATH}":${pkgs.jq}/bin/
PATH="''${PATH}":${pkgs.gnugrep}/bin/ #PATH="''${PATH}":${pkgs.rsync}/bin/
PATH="''${PATH}":${inputs.version.defaultPackage."${builtins.currentSystem}"}/bin/ #PATH="''${PATH}":${pkgs.bash}/bin/
#PATH="''${PATH}":${pkgs.curl}/bin/
export PATH #PATH="''${PATH}":${pkgs.moreutils}/bin/
#PATH="''${PATH}":${pkgs.gnutar}/bin
#PATH="''${PATH}":${pkgs.gzip}/bin/
if [ -z "'CI_JOB_TOKEN" ]; then #PATH="''${PATH}":${pkgs.procps}/bin/
version=''$(git describe --tags --always --dirty) #PATH="''${PATH}":${pkgs.eza}/bin/
buildDate=''$(date -u +"%Y-%m-%dT%H:%M:%SZ") #PATH="''${PATH}":${pkgs.git}/bin/
else #PATH="''${PATH}":${pkgs.gnugrep}/bin/
version=''$(version predict --git) #PATH="''${PATH}":${inputs.version.defaultPackage."${builtins.currentSystem}"}/bin/
buildDate=''$(version date) #
fi #export PATH
#
${config.devenv.root}/bin/go-compile.sh \ #
"${config.devenv.root}/source/" \ #if [ -z "'CI_JOB_TOKEN" ]; then
"${config.devenv.root}/dist"/ \ # version=''$(git describe --tags --always --dirty)
"version" \ # buildDate=''$(date -u +"%Y-%m-%dT%H:%M:%SZ")
"main" \ #else
"''${version}" \ # version=''$(version predict --git)
"''${buildDate}" # buildDate=''$(version date)
#fi
#
''; #${config.devenv.root}/bin/go-compile.sh \
# "${config.devenv.root}/source/" \
# "${config.devenv.root}/dist"/ \
# "version" \
# "main" \
# "''${version}" \
# "''${buildDate}"
#
#
#'';
# This scritp is used to deploy the app to the gitlab registry # This scritp is used to deploy the app to the gitlab registry
# It is used by the gitlab-ci.yml file # It is used by the gitlab-ci.yml file
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment