Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Version
Manage
Activity
Members
Plan
Jira
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OSS
Utilities
Version
Commits
c2c71cd8
Verified
Commit
c2c71cd8
authored
Jan 4, 2024
by
Volker Schukai
Browse files
Options
Downloads
Patches
Plain Diff
fix: update ci #14
parent
9216f597
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
.gitlab-ci.yml
+3
-3
3 additions, 3 deletions
.gitlab-ci.yml
devenv.nix
+117
-103
117 additions, 103 deletions
devenv.nix
project.nix
+1
-1
1 addition, 1 deletion
project.nix
treefmt.toml
+1
-1
1 addition, 1 deletion
treefmt.toml
with
122 additions
and
108 deletions
.gitlab-ci.yml
+
3
−
3
View file @
c2c71cd8
This diff is collapsed.
Click to expand it.
devenv.nix
+
117
−
103
View file @
c2c71cd8
...
@@ -8,15 +8,12 @@
...
@@ -8,15 +8,12 @@
modulesPath
,
modulesPath
,
...
...
}:
let
}:
let
taskfileYaml
=
let
taskfileYaml
=
let
ciJobToken
=
builtins
.
getEnv
"CI_JOB_TOKEN"
;
ciJobToken
=
builtins
.
getEnv
"CI_JOB_TOKEN"
;
gitCommit
=
if
ciJobToken
==
""
then
gitCommit
=
(
builtins
.
getFlake
"git+https://gitlab.schukai.com/schukai/entwicklung/nix-flakes"
)
.
packages
.
${
builtins
.
currentSystem
}
.
git-commit
if
ciJobToken
==
""
else
then
(
builtins
.
getFlake
"git+https://gitlab.schukai.com/schukai/entwicklung/nix-flakes"
)
.
packages
.
${
builtins
.
currentSystem
}
.
git-commit
""
;
else
""
;
goPkgReleaseData
=
import
./project.nix
;
goPkgReleaseData
=
import
./project.nix
;
goPkgName
=
goPkgReleaseData
.
name
or
"goPkg"
;
goPkgName
=
goPkgReleaseData
.
name
or
"goPkg"
;
...
@@ -67,7 +64,7 @@ tasks:
...
@@ -67,7 +64,7 @@ tasks:
command = "
${
pkgs
.
alejandra
}
/bin/alejandra"
command = "
${
pkgs
.
alejandra
}
/bin/alejandra"
options = []
options = []
includes = [ "*.nix" ]
includes = [ "*.nix" ]
excludes = [ "devenv.nix" ]
#
excludes = [ "devenv.nix" ]
[formatter.go]
[formatter.go]
command = "
${
pkgs
.
go
}
/bin/gofmt"
command = "
${
pkgs
.
go
}
/bin/gofmt"
...
@@ -223,7 +220,8 @@ in {
...
@@ -223,7 +220,8 @@ in {
env
.
APP_NAME
=
let
env
.
APP_NAME
=
let
goPkgReleaseData
=
import
./project.nix
;
goPkgReleaseData
=
import
./project.nix
;
goPkgMnemonic
=
goPkgReleaseData
.
mnemonic
or
"go-pkg"
;
goPkgMnemonic
=
goPkgReleaseData
.
mnemonic
or
"go-pkg"
;
in
goPkgMnemonic
;
in
goPkgMnemonic
;
# https://devenv.sh/packages/
# https://devenv.sh/packages/
packages
=
with
pkgs
;
[
packages
=
with
pkgs
;
[
...
@@ -425,7 +423,6 @@ in {
...
@@ -425,7 +423,6 @@ in {
''
;
''
;
scripts
.
update-files
.
exec
=
''
scripts
.
update-files
.
exec
=
''
#!
${
pkgs
.
bash
}
/bin/bash
#!
${
pkgs
.
bash
}
/bin/bash
source common-functions
source common-functions
...
@@ -495,6 +492,23 @@ in {
...
@@ -495,6 +492,23 @@ in {
echo "$hash"
echo "$hash"
''
;
''
;
## this script should be run after debugging the ci pipeline
scripts
.
delete-pipeline
.
exec
=
''
#!
${
pkgs
.
bash
}
/bin/bash
pipeline_list=$(glab ci list)
commit_hashes=$(echo "$pipeline_list" | awk '/#/{print $3}')
for hash in $commit_hashes; do
hh=$(echo "$hash" | cut -d"#" -f2)
echo "found hash: $hh"
glab ci delete "$hh"
done
echo "done"
''
;
scripts
.
build-app
.
exec
=
''
scripts
.
build-app
.
exec
=
''
#!
${
pkgs
.
bash
}
/bin/bash
#!
${
pkgs
.
bash
}
/bin/bash
${
pkgs
.
treefmt
}
/bin/treefmt
${
pkgs
.
treefmt
}
/bin/treefmt
...
...
This diff is collapsed.
Click to expand it.
project.nix
+
1
−
1
View file @
c2c71cd8
This diff is collapsed.
Click to expand it.
treefmt.toml
+
1
−
1
View file @
c2c71cd8
/nix/store/wrp2lsy6h8mzr6fa4n71lqnxw5dliwmc-treefmt.toml
/nix/store/f7brr7ah00s9303lhvk338lnyb1ifrys-treefmt.toml
\ No newline at end of file
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment