Compare commits

..

4 Commits

Author SHA1 Message Date
0187d4031c Slightly cleaner error reporting.
Some checks failed
Fibonacci container test / Containerize (push) Failing after 30s
Fibonacci unit tests / Run-unit-tests (push) Successful in 44s
2025-08-25 13:16:43 +02:00
e5aced29a3 Signing policy added.
Some checks failed
Fibonacci unit tests / Containerize (push) Failing after 4s
Fibonacci unit tests / Run-unit-tests (push) Successful in 23s
2025-08-11 20:46:25 +02:00
8605f39f53 Merge pull request 'Changed things around. Should fix docker compilation' (#1) from daanselen/fibonacci:build into build
Some checks failed
Fibonacci unit tests / Containerize (push) Failing after 5s
Fibonacci unit tests / Run-unit-tests (push) Successful in 19s
Reviewed-on: #1
2025-08-11 14:54:39 +00:00
aa601454fd Changed things around. Should fix docker compilation 2025-08-11 16:35:16 +02:00
6 changed files with 49 additions and 10 deletions

View File

@@ -1,5 +1,5 @@
name: Fibonacci unit tests
run-name: ${{ gitea.actor }} is testing Fibonacci
name: Fibonacci container test
run-name: ${{ gitea.actor }} is testing Fibonacci containerization
on:
push:
branches:

1
code/.gitignore vendored
View File

@@ -11,6 +11,7 @@
# But not these files...
!/.gitignore
!functions/*.go
!*.go
!go.sum
!go.mod

View File

@@ -1,7 +1,6 @@
package functions
import(
"errors"
import (
"fmt"
)
@@ -11,7 +10,7 @@ func MyFibonacci(count int) (fibonaccivalue int, error error) {
var prev_fibonacci int = 0
if count < 1 {
return -1, errors.New(fmt.Sprintf("%d is not a positive integer.",count))
return -1, fmt.Errorf("%d is not a positive integer", count)
}
for i := 1; i < count; i++ {
fibonaccivalue += prev_fibonacci

View File

@@ -1,4 +1,5 @@
module darjeeling.systemec.nl/rhouben/fibonacci
replace darjeeling.systemec.nl/rhouben/fibonacci/functions => ./functions
go 1.24.4

View File

@@ -1,15 +1,14 @@
FROM golang:1.23-bookworm AS base
FROM golang:1.24-bookworm AS base
# /build is the working directory
WORKDIR /build
# Copy control files and pull in dependencies
COPY code/go.mod .
RUN go mod download
COPY code/ ./
RUN go mod tidy \
&& go mod download
ENV port=8089
# Copy the rest of the source code into the container
COPY code/* .
# Build the app

39
openpgp-policy.toml Normal file
View File

@@ -0,0 +1,39 @@
version = 0
commit_goodlist = []
[authorization."Rens Houben <lpmhouben@gmail.com>"]
sign_commit = true
sign_tag = true
sign_archive = true
add_user = true
retire_user = true
audit = true
keyring = """
-----BEGIN PGP PUBLIC KEY BLOCK-----
Comment: E440 6FB1 B3DE 72FC BB5A 31B6 B9BD 7068 7972 7348 DF96 C300 16E9 1615 C1CA 3244
Comment: <lpmhouben@gmail.com>
Comment: Rens Houben
xioGaJm15RsAAAAgaN/rppCWy2CMp+ptpgSv+PdNrRto2adth6QmlOwgZoPCrAYf
GwoAAAA9BYJombXlBYkFpI+9AwsJBwMVCggCmwECHgkiIQbkQG+xs95y/LtaMba5
vXBoeXJzSN+WwwAW6RYVwcoyRAAAAABf0iCRI80vGSLlZ05nqtSy1X9tkRrt9ZXH
F5RZlDdGUF00mfPBZnIYcHyNu7KQpfz5XS8O7vC27fDjx0EgY6s9b0Y5GPmTZEpk
jIs2ijl5teaaiwPPh6ow5Kg57v92EOFEUAfNFTxscG1ob3ViZW5AZ21haWwuY29t
PsKsBhMbCgAAAD0FgmiZteUFiQWkj70DCwkHAxUKCAKbAQIeCSIhBuRAb7Gz3nL8
u1oxtrm9cGh5cnNI35bDABbpFhXByjJEAAAAAJHaIFARgIT42hWyM6UPxr42sPKd
jlPALYaYHOYuVtDbb/CHA4LBgfwmSGdRimrf9Sq3+rAmb5JSLipYcd3mnrWBIjqc
wpdz0ClJC01ZzT9Rw4pnOoZueH90ApxVjOjPd0PBAc0LUmVucyBIb3ViZW7CrwYT
GwoAAABABYJombXlBYkFpI+9AwsJBwMVCggCmQECmwECHgkiIQbkQG+xs95y/Lta
Mba5vXBoeXJzSN+WwwAW6RYVwcoyRAAAAABhmSDBodFpCvgrvmxI5gPOArSU3BDX
4WXqK8uN08ppnKjno6jWPwVMh4mtQZZhVIuZnNvIpnb4fZIa3npwBVFGw/fK6phj
0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