mirror of
https://codeberg.org/scip/tablizer.git
synced 2025-12-19 05:21:03 +01:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| fe351116d6 | |||
| db35d08385 |
32
.woodpecker/image.yaml
Normal file
32
.woodpecker/image.yaml
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
# https://woodpecker-ci.org/plugins/docker-buildx
|
||||||
|
# enable Package unit and go to /scip/-/packages after building to link to proj
|
||||||
|
|
||||||
|
variables:
|
||||||
|
- &repo codeberg.org/${CI_REPO_OWNER}/tablizer
|
||||||
|
|
||||||
|
steps:
|
||||||
|
dryrun:
|
||||||
|
image: docker.io/woodpeckerci/plugin-docker-buildx:latest
|
||||||
|
settings:
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
platforms: linux/amd64
|
||||||
|
dry_run: true
|
||||||
|
repo: *repo
|
||||||
|
tags: latest
|
||||||
|
when:
|
||||||
|
event: [pull_request]
|
||||||
|
|
||||||
|
publish:
|
||||||
|
image: docker.io/woodpeckerci/plugin-docker-buildx:latest
|
||||||
|
settings:
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
platforms: linux/amd64
|
||||||
|
repo: *repo
|
||||||
|
registry: codeberg.org
|
||||||
|
tags: latest,${CI_COMMIT_SHA:0:8},${CI_COMMIT_TAG}
|
||||||
|
username: ${CI_REPO_OWNER}
|
||||||
|
password:
|
||||||
|
from_secret: REGISTRY_TOKEN
|
||||||
|
when:
|
||||||
|
event: [tag]
|
||||||
|
branch: main
|
||||||
@@ -23,8 +23,8 @@ import (
|
|||||||
"sort"
|
"sort"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"codeberg.org/scip/tablizer/cfg"
|
|
||||||
"github.com/araddon/dateparse"
|
"github.com/araddon/dateparse"
|
||||||
|
"codeberg.org/scip/tablizer/cfg"
|
||||||
)
|
)
|
||||||
|
|
||||||
func sortTable(conf cfg.Config, data *Tabdata) {
|
func sortTable(conf cfg.Config, data *Tabdata) {
|
||||||
@@ -38,12 +38,6 @@ func sortTable(conf cfg.Config, data *Tabdata) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, column := range conf.UseSortByColumn {
|
|
||||||
if column > len(data.headers) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// actual sorting
|
// actual sorting
|
||||||
sort.SliceStable(data.entries, func(i, j int) bool {
|
sort.SliceStable(data.entries, func(i, j int) bool {
|
||||||
// holds the result of a sort of one column
|
// holds the result of a sort of one column
|
||||||
|
|||||||
Reference in New Issue
Block a user