Skip to content

Commit

Permalink
Fix additional steps.
Browse files Browse the repository at this point in the history
  • Loading branch information
svetlyak40wt committed Feb 27, 2024
1 parent 97888ef commit fc965e1
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 129 deletions.
85 changes: 0 additions & 85 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,38 +34,6 @@
"cache": "true"
}
},
{
"name": "Checkout Code",
"uses": "actions/checkout@v4"
},
{
"name": "Setup Common Lisp Environment",
"uses": "40ants/setup-lisp@v4",
"with": {
"asdf-system": "40ants-ci",
"cache": "false"
}
},
{
"name": "Change dist to Ultralisp if qlfile does not exist",
"run": "if [[ ! -e qlfile ]]; then echo 'dist ultralisp http://dist.ultralisp.org' > qlfile; fi",
"shell": "bash"
},
{
"name": "Update Qlot",
"run": "qlot update --no-deps",
"shell": "bash"
},
{
"name": "Install SBLint wrapper",
"run": "qlot exec ros install 40ants-asdf-system 40ants-linter",
"shell": "bash"
},
{
"name": "Run Linter",
"run": "qlot exec 40ants-linter --system \"40ants-ci, 40ants-ci-tests\" --imports",
"shell": "bash"
},
{
"name": "Change dist to Ultralisp if qlfile does not exist",
"run": "if [[ ! -e qlfile ]]; then echo 'dist ultralisp http://dist.ultralisp.org' > qlfile; fi",
Expand Down Expand Up @@ -108,38 +76,6 @@
"cache": "true"
}
},
{
"name": "Checkout Code",
"uses": "actions/checkout@v4"
},
{
"name": "Setup Common Lisp Environment",
"uses": "40ants/setup-lisp@v4",
"with": {
"asdf-system": "40ants-ci",
"cache": "false"
}
},
{
"name": "Change dist to Ultralisp",
"run": "echo 'dist ultralisp http://dist.ultralisp.org' > qlfile",
"shell": "bash"
},
{
"name": "Update Qlot",
"run": "qlot update || qlot update",
"shell": "bash"
},
{
"name": "Install LISP-CRITIC wrapper",
"run": "qlot exec ros install 40ants-critic",
"shell": "bash"
},
{
"name": "Run Critic for \"40ants-ci\" system",
"run": "qlot exec lisp-critic --ignore function-too-long,check-prefix 40ants-ci",
"shell": "bash"
},
{
"name": "Change dist to Ultralisp",
"run": "echo 'dist ultralisp http://dist.ultralisp.org' > qlfile",
Expand Down Expand Up @@ -200,27 +136,6 @@
"cache": "true"
}
},
{
"name": "Checkout Code",
"uses": "actions/checkout@v4"
},
{
"name": "Setup Common Lisp Environment",
"uses": "40ants/setup-lisp@v4",
"with": {
"asdf-system": "40ants-ci",
"qlfile-template": "{% ifequal quicklisp_dist \"ultralisp\" %}\ndist ultralisp http://dist.ultralisp.org\n{% endifequal %}",
"cache": "false"
}
},
{
"name": "Run Tests",
"uses": "40ants/run-tests@v2",
"with": {
"asdf-system": "40ants-ci",
"coveralls-token": "\n${{ matrix.lisp == 'sbcl-bin' &&\n matrix.os == 'ubuntu-latest' &&\n matrix.quicklisp == 'ultralisp' &&\n secrets.github_token }}"
}
},
{
"name": "Run Tests",
"uses": "40ants/run-tests@v2",
Expand Down
20 changes: 0 additions & 20 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,6 @@
"cache": "true"
}
},
{
"name": "Checkout Code",
"uses": "actions/checkout@v4"
},
{
"name": "Setup Common Lisp Environment",
"uses": "40ants/setup-lisp@v4",
"with": {
"asdf-system": "40ants-ci",
"cache": "false"
}
},
{
"name": "Build Docs",
"uses": "40ants/build-docs@v1",
"with": {
"asdf-system": "40ants-ci",
"error-on-warnings": true
}
},
{
"name": "Build Docs",
"uses": "40ants/build-docs@v1",
Expand Down
16 changes: 0 additions & 16 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,6 @@
"OS": "ubuntu-latest"
},
"steps": [
{
"name": "Checkout Code",
"uses": "actions/checkout@v4"
},
{
"name": "Create release tag",
"uses": "butlerlogic/action-autotag@8bc1ad456dcdee34e8c6ffbce991cc31793578c2",
"with": {
"root": "ChangeLog.md",
"regex_pattern": "^## (?<version>\\d+\\.\\d+\\.\\d+.*?)( |\\n).*$",
"tag_prefix": "v"
},
"env": {
"GITHUB_TOKEN": "${{ secrets.GITHUB_TOKEN }}"
}
},
{
"name": "Checkout Code",
"uses": "actions/checkout@v4"
Expand Down
25 changes: 17 additions & 8 deletions src/jobs/job.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
#:make-matrix
#:make-env
#:permissions
#:make-permissions))
#:make-permissions
#:explicit-steps))
(in-package #:40ants-ci/jobs/job)


Expand All @@ -33,7 +34,8 @@
:documentation "A list of plists denoting matrix combinations to be excluded.")
(steps :initform nil
:initarg :steps
:reader steps)
:documentation "This slot holds steps given as a STEPS argument to a job constructor. Depending on a job class, it might add additional steps around these explicit steps."
:reader explicit-steps)
(permissions :initform nil
:initarg :permissions
:documentation "A plist of permissions need for running the job.
Expand All @@ -53,18 +55,25 @@
(unless (slot-boundp job 'name)
(setf (slot-value job 'name)
(string-downcase
(class-name (class-of job)))
(slot-value job 'steps)
(class-name (class-of job))))
(setf (slot-value job 'steps)
(mapcar #'ensure-step
(steps job)))))
(slot-value job 'steps)))))


(defmethod os :around ((job job))
(uiop:ensure-list
(call-next-method)))

(defmethod steps :around ((job job))
(uiop:ensure-list
(call-next-method)))

(defgeneric steps (job)
(:method ((job job))
(explicit-steps job))

(:method :around ((job job))
(uiop:ensure-list
(call-next-method))))


(defmethod exclude :around ((job job))
(ensure-list-of-plists
Expand Down

0 comments on commit fc965e1

Please sign in to comment.