Compare commits
15 Commits
84b8ddb582
...
no_add
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
99f97874ea
|
||
|
|
6c3df1d4cd
|
||
|
|
336b5d3d54
|
||
|
|
cef89303b1
|
||
|
|
842a77fb2b
|
||
|
|
957bb3a5c8
|
||
|
|
de6739f9b6
|
||
|
|
656e26e26f
|
||
|
|
49fbb17672
|
||
|
|
8c8152bbfc
|
||
|
|
3a84926d9f
|
||
|
|
0b125fc88e
|
||
|
|
27342b0a44
|
||
|
|
76ecd25002
|
||
|
|
482d5ecfa3 |
@@ -3,3 +3,4 @@ target
|
|||||||
Cargo.lock
|
Cargo.lock
|
||||||
notes/
|
notes/
|
||||||
.lighthouse/
|
.lighthouse/
|
||||||
|
/.webhook_bridge/
|
||||||
|
|||||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1,3 +1,3 @@
|
|||||||
/target
|
/target
|
||||||
Cargo.lock
|
|
||||||
TODO.org
|
TODO.org
|
||||||
|
/result
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ apiVersion: tekton.dev/v1
|
|||||||
kind: PipelineRun
|
kind: PipelineRun
|
||||||
metadata:
|
metadata:
|
||||||
name: build
|
name: build
|
||||||
|
labels:
|
||||||
|
pdb: protect
|
||||||
spec:
|
spec:
|
||||||
timeouts:
|
timeouts:
|
||||||
pipeline: "2h0m0s"
|
pipeline: "2h0m0s"
|
||||||
@@ -50,18 +52,6 @@ spec:
|
|||||||
- name: TARGET_URL
|
- name: TARGET_URL
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
||||||
- name: fetch-repository
|
- name: fetch-repository
|
||||||
taskRef:
|
|
||||||
resolver: git
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: https://code.fizz.buzz/mirror/catalog.git # mirror of https://github.com/tektoncd/catalog.git
|
|
||||||
- name: revision
|
|
||||||
value: df36b3853a5657fd883015cdbf07ad6466918acf
|
|
||||||
- name: pathInRepo
|
|
||||||
value: task/git-clone/0.9/git-clone.yaml
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
params:
|
||||||
- name: url
|
- name: url
|
||||||
value: $(params.REPO_URL)
|
value: $(params.REPO_URL)
|
||||||
@@ -69,6 +59,18 @@ spec:
|
|||||||
value: $(params.PULL_BASE_SHA)
|
value: $(params.PULL_BASE_SHA)
|
||||||
- name: deleteExisting
|
- name: deleteExisting
|
||||||
value: "true"
|
value: "true"
|
||||||
|
taskRef:
|
||||||
|
params:
|
||||||
|
- name: url
|
||||||
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
|
- name: revision
|
||||||
|
value: "dda7b690195b43e8b9859d1caf5dcbf48588ade1"
|
||||||
|
- name: pathInRepo
|
||||||
|
value: task/git-clone/0.1/git-clone.yaml
|
||||||
|
resolver: git
|
||||||
|
workspaces:
|
||||||
|
- name: output
|
||||||
|
workspace: git-source
|
||||||
- name: get-git-commit-time
|
- name: get-git-commit-time
|
||||||
taskSpec:
|
taskSpec:
|
||||||
metadata: {}
|
metadata: {}
|
||||||
@@ -101,7 +103,7 @@ spec:
|
|||||||
- name: url
|
- name: url
|
||||||
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
- name: revision
|
- name: revision
|
||||||
value: 7ee31a185243ee6da13dcd26a592c585b64c80e5
|
value: dda7b690195b43e8b9859d1caf5dcbf48588ade1
|
||||||
- name: pathInRepo
|
- name: pathInRepo
|
||||||
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
||||||
params:
|
params:
|
||||||
@@ -145,11 +147,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -169,6 +170,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -188,11 +191,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -212,6 +214,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -231,11 +235,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -255,6 +258,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -274,11 +279,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -298,6 +302,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -317,11 +323,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -341,6 +346,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -360,11 +367,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -389,6 +395,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -408,11 +416,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -437,6 +444,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -456,11 +465,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -491,6 +499,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -510,11 +520,10 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
stepTemplate:
|
stepTemplate:
|
||||||
image: alpine:3.18
|
image: alpine:3.20
|
||||||
name: ""
|
computeResources:
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 60Mi
|
||||||
@@ -541,6 +550,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -619,17 +630,13 @@ spec:
|
|||||||
- name: docker-image
|
- name: docker-image
|
||||||
type: string
|
type: string
|
||||||
description: Docker image to run.
|
description: Docker image to run.
|
||||||
default: alpine:3.18
|
default: alpine:3.20
|
||||||
- name: cache-subdir
|
stepTemplate:
|
||||||
type: string
|
image: alpine:3.20
|
||||||
description: subPath used in the persistent volume for the cargo cache.
|
computeResources:
|
||||||
steptemplate:
|
|
||||||
image: alpine:3.18
|
|
||||||
name: ""
|
|
||||||
resources:
|
|
||||||
requests:
|
requests:
|
||||||
cpu: 10m
|
cpu: 10m
|
||||||
memory: 60Mi
|
memory: 600Mi
|
||||||
workingDir: /workspace/source
|
workingDir: /workspace/source
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
@@ -641,21 +648,19 @@ spec:
|
|||||||
- name: run
|
- name: run
|
||||||
image: $(params.docker-image)
|
image: $(params.docker-image)
|
||||||
workingDir: "$(workspaces.source.path)"
|
workingDir: "$(workspaces.source.path)"
|
||||||
command: ["ls", "$(workspaces.cargo-cache.path)"]
|
command: [cargo, cache, --autoclean]
|
||||||
# command: [echo, $(params.cache-subdir)]
|
|
||||||
# command: [cargo, cache, --autoclean]
|
|
||||||
args: []
|
args: []
|
||||||
|
env:
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
- name: cargo-cache
|
- name: cargo-cache
|
||||||
workspace: cargo-cache
|
workspace: cargo-cache
|
||||||
subPath: $(params.cache-subdir)
|
|
||||||
params:
|
params:
|
||||||
- name: docker-image
|
- name: docker-image
|
||||||
value: "$(tasks.build-image.results.IMAGE_URL[1])"
|
value: "$(tasks.build-image.results.IMAGE_URL[1])"
|
||||||
- name: cache-subdir
|
|
||||||
value: none
|
|
||||||
# matrix:
|
# matrix:
|
||||||
# params:
|
# params:
|
||||||
# - name: cache-subdir
|
# - name: cache-subdir
|
||||||
@@ -677,7 +682,7 @@ spec:
|
|||||||
- name: git-source
|
- name: git-source
|
||||||
volumeClaimTemplate:
|
volumeClaimTemplate:
|
||||||
spec:
|
spec:
|
||||||
storageClassName: "nfs-client"
|
storageClassName: "local-path"
|
||||||
accessModes:
|
accessModes:
|
||||||
- ReadWriteOnce
|
- ReadWriteOnce
|
||||||
resources:
|
resources:
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ apiVersion: tekton.dev/v1
|
|||||||
kind: PipelineRun
|
kind: PipelineRun
|
||||||
metadata:
|
metadata:
|
||||||
name: foreign-document-test
|
name: foreign-document-test
|
||||||
|
labels:
|
||||||
|
pdb: protect
|
||||||
spec:
|
spec:
|
||||||
timeouts:
|
timeouts:
|
||||||
pipeline: "2h0m0s"
|
pipeline: "2h0m0s"
|
||||||
@@ -50,18 +52,6 @@ spec:
|
|||||||
- name: TARGET_URL
|
- name: TARGET_URL
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
||||||
- name: fetch-repository
|
- name: fetch-repository
|
||||||
taskRef:
|
|
||||||
resolver: git
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: https://code.fizz.buzz/mirror/catalog.git # mirror of https://github.com/tektoncd/catalog.git
|
|
||||||
- name: revision
|
|
||||||
value: df36b3853a5657fd883015cdbf07ad6466918acf
|
|
||||||
- name: pathInRepo
|
|
||||||
value: task/git-clone/0.9/git-clone.yaml
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
params:
|
||||||
- name: url
|
- name: url
|
||||||
value: $(params.REPO_URL)
|
value: $(params.REPO_URL)
|
||||||
@@ -69,6 +59,18 @@ spec:
|
|||||||
value: $(params.PULL_BASE_SHA)
|
value: $(params.PULL_BASE_SHA)
|
||||||
- name: deleteExisting
|
- name: deleteExisting
|
||||||
value: "true"
|
value: "true"
|
||||||
|
taskRef:
|
||||||
|
params:
|
||||||
|
- name: url
|
||||||
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
|
- name: revision
|
||||||
|
value: "dda7b690195b43e8b9859d1caf5dcbf48588ade1"
|
||||||
|
- name: pathInRepo
|
||||||
|
value: task/git-clone/0.1/git-clone.yaml
|
||||||
|
resolver: git
|
||||||
|
workspaces:
|
||||||
|
- name: output
|
||||||
|
workspace: git-source
|
||||||
- name: get-git-commit-time
|
- name: get-git-commit-time
|
||||||
taskSpec:
|
taskSpec:
|
||||||
metadata: {}
|
metadata: {}
|
||||||
@@ -101,7 +103,7 @@ spec:
|
|||||||
- name: url
|
- name: url
|
||||||
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
- name: revision
|
- name: revision
|
||||||
value: 7ee31a185243ee6da13dcd26a592c585b64c80e5
|
value: dda7b690195b43e8b9859d1caf5dcbf48588ade1
|
||||||
- name: pathInRepo
|
- name: pathInRepo
|
||||||
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
||||||
params:
|
params:
|
||||||
@@ -165,6 +167,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -261,6 +265,9 @@ spec:
|
|||||||
workingDir: "$(workspaces.source.path)"
|
workingDir: "$(workspaces.source.path)"
|
||||||
command: [cargo, cache, --autoclean]
|
command: [cargo, cache, --autoclean]
|
||||||
args: []
|
args: []
|
||||||
|
env:
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -277,7 +284,7 @@ spec:
|
|||||||
- name: git-source
|
- name: git-source
|
||||||
volumeClaimTemplate:
|
volumeClaimTemplate:
|
||||||
spec:
|
spec:
|
||||||
storageClassName: "nfs-client"
|
storageClassName: "local-path"
|
||||||
accessModes:
|
accessModes:
|
||||||
- ReadWriteOnce
|
- ReadWriteOnce
|
||||||
resources:
|
resources:
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ apiVersion: tekton.dev/v1
|
|||||||
kind: PipelineRun
|
kind: PipelineRun
|
||||||
metadata:
|
metadata:
|
||||||
name: rust-format
|
name: rust-format
|
||||||
|
labels:
|
||||||
|
pdb: protect
|
||||||
spec:
|
spec:
|
||||||
timeouts:
|
timeouts:
|
||||||
pipeline: "2h0m0s"
|
pipeline: "2h0m0s"
|
||||||
@@ -50,18 +52,6 @@ spec:
|
|||||||
- name: TARGET_URL
|
- name: TARGET_URL
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
||||||
- name: fetch-repository
|
- name: fetch-repository
|
||||||
taskRef:
|
|
||||||
resolver: git
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: https://code.fizz.buzz/mirror/catalog.git # mirror of https://github.com/tektoncd/catalog.git
|
|
||||||
- name: revision
|
|
||||||
value: df36b3853a5657fd883015cdbf07ad6466918acf
|
|
||||||
- name: pathInRepo
|
|
||||||
value: task/git-clone/0.9/git-clone.yaml
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
params:
|
||||||
- name: url
|
- name: url
|
||||||
value: $(params.REPO_URL)
|
value: $(params.REPO_URL)
|
||||||
@@ -69,6 +59,18 @@ spec:
|
|||||||
value: $(params.PULL_BASE_SHA)
|
value: $(params.PULL_BASE_SHA)
|
||||||
- name: deleteExisting
|
- name: deleteExisting
|
||||||
value: "true"
|
value: "true"
|
||||||
|
taskRef:
|
||||||
|
params:
|
||||||
|
- name: url
|
||||||
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
|
- name: revision
|
||||||
|
value: "dda7b690195b43e8b9859d1caf5dcbf48588ade1"
|
||||||
|
- name: pathInRepo
|
||||||
|
value: task/git-clone/0.1/git-clone.yaml
|
||||||
|
resolver: git
|
||||||
|
workspaces:
|
||||||
|
- name: output
|
||||||
|
workspace: git-source
|
||||||
- name: get-git-commit-time
|
- name: get-git-commit-time
|
||||||
taskSpec:
|
taskSpec:
|
||||||
metadata: {}
|
metadata: {}
|
||||||
@@ -101,7 +103,7 @@ spec:
|
|||||||
- name: url
|
- name: url
|
||||||
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
- name: revision
|
- name: revision
|
||||||
value: 7ee31a185243ee6da13dcd26a592c585b64c80e5
|
value: dda7b690195b43e8b9859d1caf5dcbf48588ade1
|
||||||
- name: pathInRepo
|
- name: pathInRepo
|
||||||
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
||||||
params:
|
params:
|
||||||
@@ -167,6 +169,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -294,6 +298,9 @@ spec:
|
|||||||
workingDir: "$(workspaces.source.path)"
|
workingDir: "$(workspaces.source.path)"
|
||||||
command: [cargo, cache, --autoclean]
|
command: [cargo, cache, --autoclean]
|
||||||
args: []
|
args: []
|
||||||
|
env:
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -310,7 +317,7 @@ spec:
|
|||||||
- name: git-source
|
- name: git-source
|
||||||
volumeClaimTemplate:
|
volumeClaimTemplate:
|
||||||
spec:
|
spec:
|
||||||
storageClassName: "nfs-client"
|
storageClassName: "local-path"
|
||||||
accessModes:
|
accessModes:
|
||||||
- ReadWriteOnce
|
- ReadWriteOnce
|
||||||
resources:
|
resources:
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ apiVersion: tekton.dev/v1
|
|||||||
kind: PipelineRun
|
kind: PipelineRun
|
||||||
metadata:
|
metadata:
|
||||||
name: rust-clippy
|
name: rust-clippy
|
||||||
|
labels:
|
||||||
|
pdb: protect
|
||||||
spec:
|
spec:
|
||||||
taskRunTemplate:
|
taskRunTemplate:
|
||||||
serviceAccountName: build-bot
|
serviceAccountName: build-bot
|
||||||
@@ -50,18 +52,6 @@ spec:
|
|||||||
- name: TARGET_URL
|
- name: TARGET_URL
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
||||||
- name: fetch-repository
|
- name: fetch-repository
|
||||||
taskRef:
|
|
||||||
resolver: git
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: https://code.fizz.buzz/mirror/catalog.git # mirror of https://github.com/tektoncd/catalog.git
|
|
||||||
- name: revision
|
|
||||||
value: df36b3853a5657fd883015cdbf07ad6466918acf
|
|
||||||
- name: pathInRepo
|
|
||||||
value: task/git-clone/0.9/git-clone.yaml
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
params:
|
||||||
- name: url
|
- name: url
|
||||||
value: $(params.REPO_URL)
|
value: $(params.REPO_URL)
|
||||||
@@ -69,6 +59,18 @@ spec:
|
|||||||
value: $(params.PULL_BASE_SHA)
|
value: $(params.PULL_BASE_SHA)
|
||||||
- name: deleteExisting
|
- name: deleteExisting
|
||||||
value: "true"
|
value: "true"
|
||||||
|
taskRef:
|
||||||
|
params:
|
||||||
|
- name: url
|
||||||
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
|
- name: revision
|
||||||
|
value: "dda7b690195b43e8b9859d1caf5dcbf48588ade1"
|
||||||
|
- name: pathInRepo
|
||||||
|
value: task/git-clone/0.1/git-clone.yaml
|
||||||
|
resolver: git
|
||||||
|
workspaces:
|
||||||
|
- name: output
|
||||||
|
workspace: git-source
|
||||||
- name: get-git-commit-time
|
- name: get-git-commit-time
|
||||||
taskSpec:
|
taskSpec:
|
||||||
metadata: {}
|
metadata: {}
|
||||||
@@ -101,7 +103,7 @@ spec:
|
|||||||
- name: url
|
- name: url
|
||||||
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
- name: revision
|
- name: revision
|
||||||
value: 7ee31a185243ee6da13dcd26a592c585b64c80e5
|
value: dda7b690195b43e8b9859d1caf5dcbf48588ade1
|
||||||
- name: pathInRepo
|
- name: pathInRepo
|
||||||
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
||||||
params:
|
params:
|
||||||
@@ -177,6 +179,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -273,6 +277,9 @@ spec:
|
|||||||
workingDir: "$(workspaces.source.path)"
|
workingDir: "$(workspaces.source.path)"
|
||||||
command: [cargo, cache, --autoclean]
|
command: [cargo, cache, --autoclean]
|
||||||
args: []
|
args: []
|
||||||
|
env:
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -289,7 +296,7 @@ spec:
|
|||||||
- name: git-source
|
- name: git-source
|
||||||
volumeClaimTemplate:
|
volumeClaimTemplate:
|
||||||
spec:
|
spec:
|
||||||
storageClassName: "nfs-client"
|
storageClassName: "local-path"
|
||||||
accessModes:
|
accessModes:
|
||||||
- ReadWriteOnce
|
- ReadWriteOnce
|
||||||
resources:
|
resources:
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ apiVersion: tekton.dev/v1
|
|||||||
kind: PipelineRun
|
kind: PipelineRun
|
||||||
metadata:
|
metadata:
|
||||||
name: rust-test
|
name: rust-test
|
||||||
|
labels:
|
||||||
|
pdb: protect
|
||||||
spec:
|
spec:
|
||||||
timeouts:
|
timeouts:
|
||||||
pipeline: "2h0m0s"
|
pipeline: "2h0m0s"
|
||||||
@@ -50,18 +52,6 @@ spec:
|
|||||||
- name: TARGET_URL
|
- name: TARGET_URL
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
||||||
- name: fetch-repository
|
- name: fetch-repository
|
||||||
taskRef:
|
|
||||||
resolver: git
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: https://code.fizz.buzz/mirror/catalog.git # mirror of https://github.com/tektoncd/catalog.git
|
|
||||||
- name: revision
|
|
||||||
value: df36b3853a5657fd883015cdbf07ad6466918acf
|
|
||||||
- name: pathInRepo
|
|
||||||
value: task/git-clone/0.9/git-clone.yaml
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
params:
|
||||||
- name: url
|
- name: url
|
||||||
value: $(params.REPO_URL)
|
value: $(params.REPO_URL)
|
||||||
@@ -69,6 +59,18 @@ spec:
|
|||||||
value: $(params.PULL_BASE_SHA)
|
value: $(params.PULL_BASE_SHA)
|
||||||
- name: deleteExisting
|
- name: deleteExisting
|
||||||
value: "true"
|
value: "true"
|
||||||
|
taskRef:
|
||||||
|
params:
|
||||||
|
- name: url
|
||||||
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
|
- name: revision
|
||||||
|
value: "dda7b690195b43e8b9859d1caf5dcbf48588ade1"
|
||||||
|
- name: pathInRepo
|
||||||
|
value: task/git-clone/0.1/git-clone.yaml
|
||||||
|
resolver: git
|
||||||
|
workspaces:
|
||||||
|
- name: output
|
||||||
|
workspace: git-source
|
||||||
- name: get-git-commit-time
|
- name: get-git-commit-time
|
||||||
taskSpec:
|
taskSpec:
|
||||||
metadata: {}
|
metadata: {}
|
||||||
@@ -101,7 +103,7 @@ spec:
|
|||||||
- name: url
|
- name: url
|
||||||
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
value: https://code.fizz.buzz/talexander/personal_tekton_catalog.git
|
||||||
- name: revision
|
- name: revision
|
||||||
value: 7ee31a185243ee6da13dcd26a592c585b64c80e5
|
value: dda7b690195b43e8b9859d1caf5dcbf48588ade1
|
||||||
- name: pathInRepo
|
- name: pathInRepo
|
||||||
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
value: task/buildkit-rootless-daemonless/0.1/buildkit-rootless-daemonless.yaml
|
||||||
params:
|
params:
|
||||||
@@ -176,6 +178,8 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: CARGO_TARGET_DIR
|
- name: CARGO_TARGET_DIR
|
||||||
value: /target
|
value: /target
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -272,6 +276,9 @@ spec:
|
|||||||
workingDir: "$(workspaces.source.path)"
|
workingDir: "$(workspaces.source.path)"
|
||||||
command: [cargo, cache, --autoclean]
|
command: [cargo, cache, --autoclean]
|
||||||
args: []
|
args: []
|
||||||
|
env:
|
||||||
|
- name: RUSTUP_PERMIT_COPY_RENAME
|
||||||
|
value: "true"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -288,7 +295,7 @@ spec:
|
|||||||
- name: git-source
|
- name: git-source
|
||||||
volumeClaimTemplate:
|
volumeClaimTemplate:
|
||||||
spec:
|
spec:
|
||||||
storageClassName: "nfs-client"
|
storageClassName: "local-path"
|
||||||
accessModes:
|
accessModes:
|
||||||
- ReadWriteOnce
|
- ReadWriteOnce
|
||||||
resources:
|
resources:
|
||||||
|
|||||||
@@ -1,31 +1,31 @@
|
|||||||
version = "0.0.1"
|
version = "0.0.1"
|
||||||
|
|
||||||
[[push]]
|
# [[push]]
|
||||||
name = "rust-test"
|
# name = "rust-test"
|
||||||
source = "pipeline-rust-test.yaml"
|
# source = "pipeline-rust-test.yaml"
|
||||||
clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
# clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
||||||
skip_branches = [ "^v[0-9]+\\.[0-9]+\\.[0-9]+$" ]
|
# skip_branches = [ "^v[0-9]+\\.[0-9]+\\.[0-9]+$" ]
|
||||||
|
|
||||||
[[push]]
|
[[push]]
|
||||||
name = "foreign-document-test"
|
name = "foreign-document-test"
|
||||||
source = "pipeline-foreign-document-test.yaml"
|
source = "pipeline-foreign-document-test.yaml"
|
||||||
clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
||||||
branches = [ "^main$", "^master$" ]
|
branches = [ "^main$", "^master$", "^no_add$" ]
|
||||||
|
|
||||||
[[push]]
|
# [[push]]
|
||||||
name = "clippy"
|
# name = "clippy"
|
||||||
source = "pipeline-rust-clippy.yaml"
|
# source = "pipeline-rust-clippy.yaml"
|
||||||
clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
# clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
||||||
skip_branches = [ "^v[0-9]+\\.[0-9]+\\.[0-9]+$" ]
|
# skip_branches = [ "^v[0-9]+\\.[0-9]+\\.[0-9]+$" ]
|
||||||
|
|
||||||
[[push]]
|
# [[push]]
|
||||||
name = "format"
|
# name = "format"
|
||||||
source = "pipeline-format.yaml"
|
# source = "pipeline-format.yaml"
|
||||||
clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
# clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
||||||
skip_branches = [ "^v[0-9]+\\.[0-9]+\\.[0-9]+$" ]
|
# skip_branches = [ "^v[0-9]+\\.[0-9]+\\.[0-9]+$" ]
|
||||||
|
|
||||||
[[push]]
|
# [[push]]
|
||||||
name = "build"
|
# name = "build"
|
||||||
source = "pipeline-build-hash.yaml"
|
# source = "pipeline-build-hash.yaml"
|
||||||
clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
# clone_uri = "git@code.fizz.buzz:talexander/organic.git"
|
||||||
branches = [ "^main$", "^master$" ]
|
# branches = [ "^main$", "^master$" ]
|
||||||
|
|||||||
1446
Cargo.lock
generated
Normal file
1446
Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,5 +1,4 @@
|
|||||||
# cargo-features = ["profile-rustflags"]
|
# cargo-features = ["profile-rustflags"]
|
||||||
cargo-features = ["codegen-backend"]
|
|
||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "organic"
|
name = "organic"
|
||||||
@@ -104,9 +103,5 @@ inherits = "release"
|
|||||||
lto = true
|
lto = true
|
||||||
strip = true
|
strip = true
|
||||||
|
|
||||||
[profile.dev]
|
|
||||||
codegen-backend = "cranelift"
|
|
||||||
|
|
||||||
[profile.dev.package."*"]
|
[profile.dev.package."*"]
|
||||||
codegen-backend = "llvm"
|
|
||||||
opt-level = 3
|
opt-level = 3
|
||||||
|
|||||||
@@ -17,15 +17,27 @@ RUN apk add --no-cache build-base musl-dev git autoconf make texinfo gnutls-dev
|
|||||||
|
|
||||||
|
|
||||||
FROM build AS build-emacs
|
FROM build AS build-emacs
|
||||||
ARG EMACS_VERSION
|
|
||||||
ARG EMACS_REPO
|
ARG EMACS_REPO
|
||||||
RUN git clone --depth 1 --branch $EMACS_VERSION $EMACS_REPO /root/emacs
|
ARG EMACS_VERSION
|
||||||
|
|
||||||
|
RUN <<EOF
|
||||||
|
set -euo pipefail
|
||||||
|
IFS=$'\n\t'
|
||||||
|
mkdir -p /root/emacs
|
||||||
|
git -C /root/emacs init --initial-branch=main
|
||||||
|
git -C /root/emacs remote add origin $EMACS_REPO
|
||||||
|
git -C /root/emacs fetch origin $EMACS_VERSION
|
||||||
|
git -C /root/emacs checkout FETCH_HEAD
|
||||||
|
EOF
|
||||||
|
#ADD "$EMACS_REPO#$EMACS_VERSION" /root/emacs
|
||||||
WORKDIR /root/emacs
|
WORKDIR /root/emacs
|
||||||
RUN mkdir /root/dist
|
RUN <<EOF
|
||||||
RUN ./autogen.sh
|
mkdir /root/dist
|
||||||
RUN ./configure --prefix /usr --without-x --without-sound --with-native-compilation=aot
|
./autogen.sh
|
||||||
RUN make
|
./configure --prefix /usr --without-x --without-sound --with-native-compilation=aot
|
||||||
RUN make DESTDIR="/root/dist" install
|
make
|
||||||
|
make DESTDIR="/root/dist" install
|
||||||
|
EOF
|
||||||
|
|
||||||
|
|
||||||
FROM build AS build-org-mode
|
FROM build AS build-org-mode
|
||||||
@@ -37,8 +49,10 @@ RUN mkdir /root/dist
|
|||||||
RUN git clone $ORG_MODE_REPO /root/org-mode && git -C /root/org-mode checkout $ORG_VERSION
|
RUN git clone $ORG_MODE_REPO /root/org-mode && git -C /root/org-mode checkout $ORG_VERSION
|
||||||
# RUN mkdir /root/org-mode && git -C /root/org-mode init --initial-branch=main && git -C /root/org-mode remote add origin $ORG_REPO && git -C /root/org-mode fetch origin $ORG_VERSION && git -C /root/org-mode checkout FETCH_HEAD
|
# RUN mkdir /root/org-mode && git -C /root/org-mode init --initial-branch=main && git -C /root/org-mode remote add origin $ORG_REPO && git -C /root/org-mode fetch origin $ORG_VERSION && git -C /root/org-mode checkout FETCH_HEAD
|
||||||
WORKDIR /root/org-mode
|
WORKDIR /root/org-mode
|
||||||
RUN make compile
|
RUN <<EOF
|
||||||
RUN make DESTDIR="/root/dist" install
|
make compile
|
||||||
|
make DESTDIR="/root/dist" install
|
||||||
|
EOF
|
||||||
|
|
||||||
|
|
||||||
FROM rustlang/rust:nightly-alpine$ALPINE_VERSION AS tester
|
FROM rustlang/rust:nightly-alpine$ALPINE_VERSION AS tester
|
||||||
@@ -118,8 +132,10 @@ RUN mkdir -p $LITERATE_BUILD_EMACS_PATH && git -C $LITERATE_BUILD_EMACS_PATH ini
|
|||||||
RUN rm $LITERATE_BUILD_EMACS_PATH/unused/aws.org
|
RUN rm $LITERATE_BUILD_EMACS_PATH/unused/aws.org
|
||||||
|
|
||||||
FROM tester as foreign-document
|
FROM tester as foreign-document
|
||||||
RUN apk add --no-cache bash coreutils
|
RUN <<EOF
|
||||||
RUN mkdir /foreign_documents
|
apk add --no-cache bash coreutils
|
||||||
|
mkdir /foreign_documents
|
||||||
|
EOF
|
||||||
COPY --link --from=foreign-document-gather /foreign_documents/howardabrams /foreign_documents/howardabrams
|
COPY --link --from=foreign-document-gather /foreign_documents/howardabrams /foreign_documents/howardabrams
|
||||||
COPY --link --from=foreign-document-gather /foreign_documents/doomemacs /foreign_documents/doomemacs
|
COPY --link --from=foreign-document-gather /foreign_documents/doomemacs /foreign_documents/doomemacs
|
||||||
COPY --link --from=foreign-document-gather /foreign_documents/worg /foreign_documents/worg
|
COPY --link --from=foreign-document-gather /foreign_documents/worg /foreign_documents/worg
|
||||||
|
|||||||
48
flake.lock
generated
Normal file
48
flake.lock
generated
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
{
|
||||||
|
"nodes": {
|
||||||
|
"nixpkgs": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1780749050,
|
||||||
|
"narHash": "sha256-3av0pIjlOWQ6rDbNOmpUSvbNnJkGORQKKjb4LtCZsIY=",
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "a799d3e3886da994fa307f817a6bc705ae538eeb",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "NixOS",
|
||||||
|
"ref": "nixos-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": "nixpkgs",
|
||||||
|
"rust-overlay": "rust-overlay"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"rust-overlay": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1781407245,
|
||||||
|
"narHash": "sha256-VzJq4MmD0uyNDAceudSe1hHqcQMe9Tau0U4S+5iRGh0=",
|
||||||
|
"owner": "oxalica",
|
||||||
|
"repo": "rust-overlay",
|
||||||
|
"rev": "d5f483210eb016d66102eef22baa128b3b3233fc",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "oxalica",
|
||||||
|
"repo": "rust-overlay",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": "root",
|
||||||
|
"version": 7
|
||||||
|
}
|
||||||
162
flake.nix
Normal file
162
flake.nix
Normal file
@@ -0,0 +1,162 @@
|
|||||||
|
{
|
||||||
|
description = "Organic Org parser";
|
||||||
|
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||||
|
rust-overlay = {
|
||||||
|
url = "github:oxalica/rust-overlay";
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs =
|
||||||
|
{
|
||||||
|
self,
|
||||||
|
nixpkgs,
|
||||||
|
rust-overlay,
|
||||||
|
}:
|
||||||
|
let
|
||||||
|
forAllSystems =
|
||||||
|
func:
|
||||||
|
builtins.listToAttrs (
|
||||||
|
map (system: {
|
||||||
|
name = system;
|
||||||
|
value = func system;
|
||||||
|
}) nixpkgs.lib.systems.flakeExposed
|
||||||
|
);
|
||||||
|
in
|
||||||
|
{
|
||||||
|
devShells = forAllSystems (
|
||||||
|
system:
|
||||||
|
let
|
||||||
|
overlays = [ (import rust-overlay) ];
|
||||||
|
pkgs = import nixpkgs {
|
||||||
|
inherit system overlays;
|
||||||
|
};
|
||||||
|
rustToolchain = (pkgs.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml).override {
|
||||||
|
targets = [ "wasm32-unknown-unknown" ];
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
default = pkgs.mkShell {
|
||||||
|
nativeBuildInputs = [
|
||||||
|
rustToolchain
|
||||||
|
];
|
||||||
|
buildInputs = with pkgs; [
|
||||||
|
wasm-bindgen-cli
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
);
|
||||||
|
packages = forAllSystems (
|
||||||
|
system:
|
||||||
|
let
|
||||||
|
overlays = [ (import rust-overlay) ];
|
||||||
|
pkgs = import nixpkgs {
|
||||||
|
inherit system overlays;
|
||||||
|
};
|
||||||
|
appliedOverlay = self.overlays.default pkgs pkgs;
|
||||||
|
in
|
||||||
|
rec {
|
||||||
|
default = all;
|
||||||
|
all = pkgs.symlinkJoin {
|
||||||
|
name = "all";
|
||||||
|
paths = [
|
||||||
|
library
|
||||||
|
devTools
|
||||||
|
wasm_bundler
|
||||||
|
wasm_web
|
||||||
|
];
|
||||||
|
};
|
||||||
|
inherit (appliedOverlay.organic)
|
||||||
|
library
|
||||||
|
devTools
|
||||||
|
wasm_bundler
|
||||||
|
wasm_web
|
||||||
|
;
|
||||||
|
docker_env = pkgs.buildEnv {
|
||||||
|
name = "organic";
|
||||||
|
paths = with pkgs; [
|
||||||
|
appliedOverlay.organic.devTools
|
||||||
|
bash
|
||||||
|
uutils-coreutils-noprefix
|
||||||
|
# toybox # Smaller than uutils-coreutils?
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
);
|
||||||
|
overlays.default = final: prev: {
|
||||||
|
organic = final.lib.makeScope final.newScope (
|
||||||
|
organicScope:
|
||||||
|
let
|
||||||
|
build_wasm =
|
||||||
|
{
|
||||||
|
bindgenTarget ? null,
|
||||||
|
}:
|
||||||
|
(organicScope.callPackage ./nix/package.nix {
|
||||||
|
inherit rust-overlay;
|
||||||
|
targetBins = [
|
||||||
|
"wasm"
|
||||||
|
];
|
||||||
|
features = [ "wasm" ];
|
||||||
|
cargoBuildTarget = "wasm32-unknown-unknown";
|
||||||
|
buildType = "wasm";
|
||||||
|
}).overrideAttrs
|
||||||
|
(
|
||||||
|
old:
|
||||||
|
let
|
||||||
|
bindgen_command = [
|
||||||
|
"${final.wasm-bindgen-cli}/bin/wasm-bindgen"
|
||||||
|
"--target"
|
||||||
|
bindgenTarget
|
||||||
|
"--out-dir"
|
||||||
|
"target/wasm32-unknown-unknown/${bindgenTarget}"
|
||||||
|
"target/wasm32-unknown-unknown/wasm/wasm.wasm"
|
||||||
|
];
|
||||||
|
in
|
||||||
|
{
|
||||||
|
postBuild = ''
|
||||||
|
${final.lib.escapeShellArgs bindgen_command}
|
||||||
|
'';
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
|
mkdir -p $out/share/${bindgenTarget}
|
||||||
|
cp target/wasm32-unknown-unknown/${bindgenTarget}/* $out/share/${bindgenTarget}
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
);
|
||||||
|
in
|
||||||
|
{
|
||||||
|
library =
|
||||||
|
(organicScope.callPackage ./nix/package.nix {
|
||||||
|
inherit rust-overlay;
|
||||||
|
buildLib = true;
|
||||||
|
}).overrideAttrs
|
||||||
|
(
|
||||||
|
old:
|
||||||
|
let
|
||||||
|
in
|
||||||
|
{
|
||||||
|
installPhase = ''
|
||||||
|
mkdir -p $out/lib
|
||||||
|
cp target/*/release/liborganic.rlib $out/lib/
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
);
|
||||||
|
devTools = organicScope.callPackage ./nix/package.nix {
|
||||||
|
inherit rust-overlay;
|
||||||
|
targetBins = [
|
||||||
|
"parse"
|
||||||
|
"compare"
|
||||||
|
];
|
||||||
|
features = [ "compare" ];
|
||||||
|
};
|
||||||
|
wasm_bundler = build_wasm { bindgenTarget = "bundler"; };
|
||||||
|
wasm_web = build_wasm { bindgenTarget = "web"; };
|
||||||
|
}
|
||||||
|
);
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
82
nix/package.nix
Normal file
82
nix/package.nix
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
{
|
||||||
|
hello,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
rust-overlay,
|
||||||
|
|
||||||
|
targetBins ? [ ],
|
||||||
|
features ? [ ],
|
||||||
|
cargoBuildTarget ? null,
|
||||||
|
buildType ? null,
|
||||||
|
buildLib ? false,
|
||||||
|
}:
|
||||||
|
let
|
||||||
|
cargoToml = (lib.importTOML ../Cargo.toml);
|
||||||
|
rustPlatformFor =
|
||||||
|
pkgs:
|
||||||
|
let
|
||||||
|
rust-bin = rust-overlay.lib.mkRustBin { } pkgs;
|
||||||
|
rustToolchain = (rust-bin.fromRustupToolchainFile ../rust-toolchain.toml).override (
|
||||||
|
if cargoBuildTarget != null then
|
||||||
|
{
|
||||||
|
targets = [ cargoBuildTarget ];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{ }
|
||||||
|
);
|
||||||
|
baseRustPlatform = (
|
||||||
|
pkgs.makeRustPlatform {
|
||||||
|
cargo = rustToolchain;
|
||||||
|
rustc = rustToolchain;
|
||||||
|
}
|
||||||
|
);
|
||||||
|
rustPlatform =
|
||||||
|
if cargoBuildTarget != null then
|
||||||
|
baseRustPlatform.overrideScope (
|
||||||
|
final: prev: {
|
||||||
|
cargoBuildHook = prev.cargoBuildHook.overrideDerivation (_: {
|
||||||
|
rustcTargetSpec = cargoBuildTarget;
|
||||||
|
});
|
||||||
|
cargoInstallHook = hello;
|
||||||
|
}
|
||||||
|
)
|
||||||
|
else
|
||||||
|
baseRustPlatform;
|
||||||
|
in
|
||||||
|
rustPlatform;
|
||||||
|
in
|
||||||
|
(rustPlatformFor pkgs).buildRustPackage (
|
||||||
|
# rustPlatform.buildRustPackage (
|
||||||
|
{
|
||||||
|
pname = "organic";
|
||||||
|
version = cargoToml.package.version;
|
||||||
|
src = lib.cleanSource ../.;
|
||||||
|
|
||||||
|
cargoLock.lockFile = ../Cargo.lock;
|
||||||
|
|
||||||
|
cargoBuildFlags = builtins.concatLists [
|
||||||
|
(builtins.concatMap (targetBin: [
|
||||||
|
"--bin"
|
||||||
|
targetBin
|
||||||
|
]) targetBins)
|
||||||
|
(if buildLib then [ "--lib" ] else [ ])
|
||||||
|
(
|
||||||
|
if features != [ ] then
|
||||||
|
[
|
||||||
|
"--features"
|
||||||
|
(builtins.concatStringsSep " " features)
|
||||||
|
]
|
||||||
|
else
|
||||||
|
[ ]
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
||||||
|
// (
|
||||||
|
if buildType != null then
|
||||||
|
{
|
||||||
|
buildType = buildType;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{ }
|
||||||
|
)
|
||||||
|
)
|
||||||
4
rust-toolchain.toml
Normal file
4
rust-toolchain.toml
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
[toolchain]
|
||||||
|
channel = "nightly-2026-05-23"
|
||||||
|
profile = "default"
|
||||||
|
components = ["clippy", "rustfmt"]
|
||||||
Reference in New Issue
Block a user