Compare commits
1 Commits
v0.1.14
...
feature_ma
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
678106bb65 |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,3 +1,2 @@
|
|||||||
/target
|
/target
|
||||||
Cargo.lock
|
Cargo.lock
|
||||||
TODO.org
|
|
||||||
|
|||||||
@@ -1,191 +0,0 @@
|
|||||||
apiVersion: tekton.dev/v1beta1
|
|
||||||
kind: PipelineRun
|
|
||||||
metadata:
|
|
||||||
name: clippy
|
|
||||||
spec:
|
|
||||||
pipelineSpec:
|
|
||||||
params:
|
|
||||||
- name: image-name
|
|
||||||
description: The name for the built image
|
|
||||||
type: string
|
|
||||||
- name: path-to-image-context
|
|
||||||
description: The path to the build context
|
|
||||||
type: string
|
|
||||||
- name: path-to-dockerfile
|
|
||||||
description: The path to the Dockerfile
|
|
||||||
type: string
|
|
||||||
- name: GIT_USER_NAME
|
|
||||||
description: The username for git
|
|
||||||
type: string
|
|
||||||
default: "fluxcdbot"
|
|
||||||
- name: GIT_USER_EMAIL
|
|
||||||
description: The email for git
|
|
||||||
type: string
|
|
||||||
default: "fluxcdbot@users.noreply.github.com"
|
|
||||||
tasks:
|
|
||||||
- name: do-stuff
|
|
||||||
taskSpec:
|
|
||||||
metadata: {}
|
|
||||||
stepTemplate:
|
|
||||||
image: alpine:3.18
|
|
||||||
name: ""
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
cpu: 10m
|
|
||||||
memory: 600Mi
|
|
||||||
workingDir: /workspace/source
|
|
||||||
steps:
|
|
||||||
- image: alpine:3.18
|
|
||||||
name: do-stuff-step
|
|
||||||
script: |
|
|
||||||
#!/usr/bin/env sh
|
|
||||||
echo "hello world"
|
|
||||||
- name: report-pending
|
|
||||||
taskRef:
|
|
||||||
name: gitea-set-status
|
|
||||||
runAfter:
|
|
||||||
- fetch-repository
|
|
||||||
params:
|
|
||||||
- name: CONTEXT
|
|
||||||
value: "$(params.JOB_NAME)"
|
|
||||||
- name: REPO_FULL_NAME
|
|
||||||
value: "$(params.REPO_OWNER)/$(params.REPO_NAME)"
|
|
||||||
- name: GITEA_HOST_URL
|
|
||||||
value: code.fizz.buzz
|
|
||||||
- name: SHA
|
|
||||||
value: "$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: DESCRIPTION
|
|
||||||
value: "Build $(params.JOB_NAME) has started"
|
|
||||||
- name: STATE
|
|
||||||
value: pending
|
|
||||||
- name: TARGET_URL
|
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
|
||||||
- name: fetch-repository
|
|
||||||
taskRef:
|
|
||||||
name: git-clone
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: $(params.REPO_URL)
|
|
||||||
- name: revision
|
|
||||||
value: $(params.PULL_BASE_SHA)
|
|
||||||
- name: deleteExisting
|
|
||||||
value: "true"
|
|
||||||
- name: build-image
|
|
||||||
taskRef:
|
|
||||||
name: kaniko
|
|
||||||
params:
|
|
||||||
- name: IMAGE
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: CONTEXT
|
|
||||||
value: $(params.path-to-image-context)
|
|
||||||
- name: DOCKERFILE
|
|
||||||
value: $(params.path-to-dockerfile)
|
|
||||||
- name: BUILDER_IMAGE
|
|
||||||
value: "gcr.io/kaniko-project/executor:v1.12.1"
|
|
||||||
- name: EXTRA_ARGS
|
|
||||||
value:
|
|
||||||
- --cache=true
|
|
||||||
- --cache-copy-layers
|
|
||||||
- --cache-repo=harbor.fizz.buzz/kanikocache/cache
|
|
||||||
- --use-new-run # Should result in a speed-up
|
|
||||||
- --reproducible # To remove timestamps so layer caching works.
|
|
||||||
- --snapshot-mode=redo
|
|
||||||
- --skip-unused-stages=true
|
|
||||||
- --registry-mirror=dockerhub.dockerhub.svc.cluster.local
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: dockerconfig
|
|
||||||
workspace: docker-credentials
|
|
||||||
runAfter:
|
|
||||||
- fetch-repository
|
|
||||||
- name: clippy
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- build-image
|
|
||||||
params:
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
finally:
|
|
||||||
- name: report-success
|
|
||||||
when:
|
|
||||||
- input: "$(tasks.status)"
|
|
||||||
operator: in
|
|
||||||
values: ["Succeeded", "Completed"]
|
|
||||||
taskRef:
|
|
||||||
name: gitea-set-status
|
|
||||||
params:
|
|
||||||
- name: CONTEXT
|
|
||||||
value: "$(params.JOB_NAME)"
|
|
||||||
- name: REPO_FULL_NAME
|
|
||||||
value: "$(params.REPO_OWNER)/$(params.REPO_NAME)"
|
|
||||||
- name: GITEA_HOST_URL
|
|
||||||
value: code.fizz.buzz
|
|
||||||
- name: SHA
|
|
||||||
value: "$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: DESCRIPTION
|
|
||||||
value: "Build $(params.JOB_NAME) has succeeded"
|
|
||||||
- name: STATE
|
|
||||||
value: success
|
|
||||||
- name: TARGET_URL
|
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
|
||||||
- name: report-failure
|
|
||||||
when:
|
|
||||||
- input: "$(tasks.status)"
|
|
||||||
operator: in
|
|
||||||
values: ["Failed"]
|
|
||||||
taskRef:
|
|
||||||
name: gitea-set-status
|
|
||||||
params:
|
|
||||||
- name: CONTEXT
|
|
||||||
value: "$(params.JOB_NAME)"
|
|
||||||
- name: REPO_FULL_NAME
|
|
||||||
value: "$(params.REPO_OWNER)/$(params.REPO_NAME)"
|
|
||||||
- name: GITEA_HOST_URL
|
|
||||||
value: code.fizz.buzz
|
|
||||||
- name: SHA
|
|
||||||
value: "$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: DESCRIPTION
|
|
||||||
value: "Build $(params.JOB_NAME) has failed"
|
|
||||||
- name: STATE
|
|
||||||
value: failure
|
|
||||||
- name: TARGET_URL
|
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
|
||||||
workspaces:
|
|
||||||
- name: git-source
|
|
||||||
- name: docker-credentials
|
|
||||||
workspaces:
|
|
||||||
- name: git-source
|
|
||||||
volumeClaimTemplate:
|
|
||||||
spec:
|
|
||||||
storageClassName: "nfs-client"
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteOnce
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
subPath: rust-source
|
|
||||||
- name: cargo-cache
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: organic-cargo-cache-clippy
|
|
||||||
- name: docker-credentials
|
|
||||||
secret:
|
|
||||||
secretName: harbor-plain
|
|
||||||
serviceAccountName: build-bot
|
|
||||||
timeout: 240h0m0s
|
|
||||||
params:
|
|
||||||
- name: image-name
|
|
||||||
value: "harbor.fizz.buzz/private/organic-clippy"
|
|
||||||
- name: path-to-image-context
|
|
||||||
value: docker/organic_clippy/
|
|
||||||
- name: path-to-dockerfile
|
|
||||||
value: docker/organic_clippy/Dockerfile
|
|
||||||
@@ -1,203 +0,0 @@
|
|||||||
apiVersion: tekton.dev/v1beta1
|
|
||||||
kind: PipelineRun
|
|
||||||
metadata:
|
|
||||||
name: rust-foreign-document-test
|
|
||||||
spec:
|
|
||||||
pipelineSpec:
|
|
||||||
timeouts:
|
|
||||||
pipeline: "2h0m0s"
|
|
||||||
tasks: "1h0m40s"
|
|
||||||
finally: "0h30m0s"
|
|
||||||
params:
|
|
||||||
- name: image-name
|
|
||||||
description: The name for the built image
|
|
||||||
type: string
|
|
||||||
- name: path-to-image-context
|
|
||||||
description: The path to the build context
|
|
||||||
type: string
|
|
||||||
- name: path-to-dockerfile
|
|
||||||
description: The path to the Dockerfile
|
|
||||||
type: string
|
|
||||||
tasks:
|
|
||||||
- name: do-stuff
|
|
||||||
taskSpec:
|
|
||||||
metadata: {}
|
|
||||||
stepTemplate:
|
|
||||||
image: alpine:3.18
|
|
||||||
name: ""
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
cpu: 10m
|
|
||||||
memory: 600Mi
|
|
||||||
workingDir: /workspace/source
|
|
||||||
steps:
|
|
||||||
- image: alpine:3.18
|
|
||||||
name: do-stuff-step
|
|
||||||
script: |
|
|
||||||
#!/usr/bin/env sh
|
|
||||||
echo "hello world"
|
|
||||||
- name: report-pending
|
|
||||||
taskRef:
|
|
||||||
name: gitea-set-status
|
|
||||||
runAfter:
|
|
||||||
- fetch-repository
|
|
||||||
params:
|
|
||||||
- name: CONTEXT
|
|
||||||
value: "$(params.JOB_NAME)"
|
|
||||||
- name: REPO_FULL_NAME
|
|
||||||
value: "$(params.REPO_OWNER)/$(params.REPO_NAME)"
|
|
||||||
- name: GITEA_HOST_URL
|
|
||||||
value: code.fizz.buzz
|
|
||||||
- name: SHA
|
|
||||||
value: "$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: DESCRIPTION
|
|
||||||
value: "Build $(params.JOB_NAME) has started"
|
|
||||||
- name: STATE
|
|
||||||
value: pending
|
|
||||||
- name: TARGET_URL
|
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
|
||||||
- name: fetch-repository
|
|
||||||
taskRef:
|
|
||||||
name: git-clone
|
|
||||||
workspaces:
|
|
||||||
- name: output
|
|
||||||
workspace: git-source
|
|
||||||
params:
|
|
||||||
- name: url
|
|
||||||
value: $(params.REPO_URL)
|
|
||||||
- name: revision
|
|
||||||
value: $(params.PULL_BASE_SHA)
|
|
||||||
- name: deleteExisting
|
|
||||||
value: "true"
|
|
||||||
- name: build-image
|
|
||||||
taskRef:
|
|
||||||
name: kaniko
|
|
||||||
params:
|
|
||||||
- name: IMAGE
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: CONTEXT
|
|
||||||
value: $(params.path-to-image-context)
|
|
||||||
- name: DOCKERFILE
|
|
||||||
value: $(params.path-to-dockerfile)
|
|
||||||
- name: BUILDER_IMAGE
|
|
||||||
value: "gcr.io/kaniko-project/executor:v1.12.1"
|
|
||||||
- name: EXTRA_ARGS
|
|
||||||
value:
|
|
||||||
- --target=foreign-document-test
|
|
||||||
- --cache=true
|
|
||||||
- --cache-copy-layers
|
|
||||||
- --cache-repo=harbor.fizz.buzz/kanikocache/cache
|
|
||||||
- --use-new-run # Should result in a speed-up
|
|
||||||
- --reproducible # To remove timestamps so layer caching works.
|
|
||||||
- --snapshot-mode=redo
|
|
||||||
- --skip-unused-stages=true
|
|
||||||
- --registry-mirror=dockerhub.dockerhub.svc.cluster.local
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: dockerconfig
|
|
||||||
workspace: docker-credentials
|
|
||||||
runAfter:
|
|
||||||
- fetch-repository
|
|
||||||
- name: run-image
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- build-image
|
|
||||||
params:
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
finally:
|
|
||||||
- name: report-success
|
|
||||||
when:
|
|
||||||
- input: "$(tasks.status)"
|
|
||||||
operator: in
|
|
||||||
values: ["Succeeded", "Completed"]
|
|
||||||
taskRef:
|
|
||||||
name: gitea-set-status
|
|
||||||
params:
|
|
||||||
- name: CONTEXT
|
|
||||||
value: "$(params.JOB_NAME)"
|
|
||||||
- name: REPO_FULL_NAME
|
|
||||||
value: "$(params.REPO_OWNER)/$(params.REPO_NAME)"
|
|
||||||
- name: GITEA_HOST_URL
|
|
||||||
value: code.fizz.buzz
|
|
||||||
- name: SHA
|
|
||||||
value: "$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: DESCRIPTION
|
|
||||||
value: "Build $(params.JOB_NAME) has succeeded"
|
|
||||||
- name: STATE
|
|
||||||
value: success
|
|
||||||
- name: TARGET_URL
|
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
|
||||||
- name: report-failure
|
|
||||||
when:
|
|
||||||
- input: "$(tasks.status)"
|
|
||||||
operator: in
|
|
||||||
values: ["Failed"]
|
|
||||||
taskRef:
|
|
||||||
name: gitea-set-status
|
|
||||||
params:
|
|
||||||
- name: CONTEXT
|
|
||||||
value: "$(params.JOB_NAME)"
|
|
||||||
- name: REPO_FULL_NAME
|
|
||||||
value: "$(params.REPO_OWNER)/$(params.REPO_NAME)"
|
|
||||||
- name: GITEA_HOST_URL
|
|
||||||
value: code.fizz.buzz
|
|
||||||
- name: SHA
|
|
||||||
value: "$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: DESCRIPTION
|
|
||||||
value: "Build $(params.JOB_NAME) has failed"
|
|
||||||
- name: STATE
|
|
||||||
value: failure
|
|
||||||
- name: TARGET_URL
|
|
||||||
value: "https://tekton.fizz.buzz/#/namespaces/$(context.pipelineRun.namespace)/pipelineruns/$(context.pipelineRun.name)"
|
|
||||||
- name: cargo-cache-autoclean
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
params:
|
|
||||||
- name: command
|
|
||||||
value: [cargo, cache, --autoclean]
|
|
||||||
- name: args
|
|
||||||
value: []
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
workspaces:
|
|
||||||
- name: git-source
|
|
||||||
- name: docker-credentials
|
|
||||||
- name: cargo-cache
|
|
||||||
workspaces:
|
|
||||||
- name: git-source
|
|
||||||
volumeClaimTemplate:
|
|
||||||
spec:
|
|
||||||
storageClassName: "nfs-client"
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteOnce
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
subPath: rust-source
|
|
||||||
- name: cargo-cache
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: organic-cargo-cache-test-foreign-document
|
|
||||||
- name: docker-credentials
|
|
||||||
secret:
|
|
||||||
secretName: harbor-plain
|
|
||||||
serviceAccountName: build-bot
|
|
||||||
params:
|
|
||||||
- name: image-name
|
|
||||||
value: "harbor.fizz.buzz/private/organic-test-foreign-document"
|
|
||||||
- name: path-to-image-context
|
|
||||||
value: docker/organic_test/
|
|
||||||
- name: path-to-dockerfile
|
|
||||||
value: docker/organic_test/Dockerfile
|
|
||||||
@@ -77,9 +77,19 @@ spec:
|
|||||||
workspace: docker-credentials
|
workspace: docker-credentials
|
||||||
runAfter:
|
runAfter:
|
||||||
- fetch-repository
|
- fetch-repository
|
||||||
- name: run-image-none
|
- name: build-organic
|
||||||
taskRef:
|
taskRef:
|
||||||
name: run-docker-image
|
name: run-docker-image
|
||||||
|
matrix:
|
||||||
|
params:
|
||||||
|
- name: feature-compare
|
||||||
|
value:
|
||||||
|
- "true"
|
||||||
|
- "false"
|
||||||
|
- name: feature-tracing
|
||||||
|
value:
|
||||||
|
- "true"
|
||||||
|
- "false"
|
||||||
workspaces:
|
workspaces:
|
||||||
- name: source
|
- name: source
|
||||||
workspace: git-source
|
workspace: git-source
|
||||||
@@ -88,156 +98,22 @@ spec:
|
|||||||
runAfter:
|
runAfter:
|
||||||
- build-image
|
- build-image
|
||||||
params:
|
params:
|
||||||
- name: args
|
- name: command
|
||||||
value: ["--no-default-features"]
|
value: ["/bin/sh", "-c"]
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-tracing
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-none
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value: ["--no-default-features", "--features", "tracing"]
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-compare
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-tracing
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value: ["--no-default-features", "--features", "compare"]
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-default
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-compare
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value: []
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-tracing-compare
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-default
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value: ["--no-default-features", "--features", "tracing,compare"]
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-compare-foreign
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-tracing-compare
|
|
||||||
params:
|
|
||||||
- name: args
|
- name: args
|
||||||
value:
|
value:
|
||||||
[
|
- |
|
||||||
"--no-default-features",
|
set -euo pipefail
|
||||||
"--features",
|
IFS=$$'\n\t'
|
||||||
"compare,foreign_document_test",
|
features=()
|
||||||
]
|
if [ $(params.feature-compare) = "true" ]; then features+=(compare); fi
|
||||||
- name: docker-image
|
if [ $(params.feature-tracing) = "true" ]; then features+=(tracing); fi
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
if [ $${#features[@]} -eq 0 ]; then
|
||||||
- name: run-image-all
|
exec cargo build --no-default-features
|
||||||
taskRef:
|
else
|
||||||
name: run-docker-image
|
featurelist=$$(IFS="," ; echo "$${features[*]}")
|
||||||
workspaces:
|
exec cargo build --no-default-features --features "$$featurelist"
|
||||||
- name: source
|
fi
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-compare-foreign
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value:
|
|
||||||
[
|
|
||||||
"--no-default-features",
|
|
||||||
"--features",
|
|
||||||
"tracing,compare,foreign_document_test",
|
|
||||||
]
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-wasm
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-all
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value:
|
|
||||||
[
|
|
||||||
"--target",
|
|
||||||
"wasm32-unknown-unknown",
|
|
||||||
"--profile",
|
|
||||||
"wasm",
|
|
||||||
"--bin",
|
|
||||||
"wasm",
|
|
||||||
"--no-default-features",
|
|
||||||
"--features",
|
|
||||||
"wasm",
|
|
||||||
]
|
|
||||||
- name: docker-image
|
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
|
||||||
- name: run-image-wasm-test
|
|
||||||
taskRef:
|
|
||||||
name: run-docker-image
|
|
||||||
workspaces:
|
|
||||||
- name: source
|
|
||||||
workspace: git-source
|
|
||||||
- name: cargo-cache
|
|
||||||
workspace: cargo-cache
|
|
||||||
runAfter:
|
|
||||||
- run-image-wasm
|
|
||||||
params:
|
|
||||||
- name: args
|
|
||||||
value:
|
|
||||||
[
|
|
||||||
"--bin",
|
|
||||||
"wasm_test",
|
|
||||||
"--no-default-features",
|
|
||||||
"--features",
|
|
||||||
"wasm_test",
|
|
||||||
]
|
|
||||||
- name: docker-image
|
- name: docker-image
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
||||||
finally:
|
finally:
|
||||||
|
|||||||
@@ -18,6 +18,14 @@ spec:
|
|||||||
- name: path-to-dockerfile
|
- name: path-to-dockerfile
|
||||||
description: The path to the Dockerfile
|
description: The path to the Dockerfile
|
||||||
type: string
|
type: string
|
||||||
|
- name: command
|
||||||
|
type: array
|
||||||
|
description: Command to run.
|
||||||
|
default: []
|
||||||
|
- name: args
|
||||||
|
type: array
|
||||||
|
description: Arguments passed to command.
|
||||||
|
default: []
|
||||||
tasks:
|
tasks:
|
||||||
- name: do-stuff
|
- name: do-stuff
|
||||||
taskSpec:
|
taskSpec:
|
||||||
@@ -83,7 +91,6 @@ spec:
|
|||||||
value: "gcr.io/kaniko-project/executor:v1.12.1"
|
value: "gcr.io/kaniko-project/executor:v1.12.1"
|
||||||
- name: EXTRA_ARGS
|
- name: EXTRA_ARGS
|
||||||
value:
|
value:
|
||||||
- --target=tester
|
|
||||||
- --cache=true
|
- --cache=true
|
||||||
- --cache-copy-layers
|
- --cache-copy-layers
|
||||||
- --cache-repo=harbor.fizz.buzz/kanikocache/cache
|
- --cache-repo=harbor.fizz.buzz/kanikocache/cache
|
||||||
@@ -110,17 +117,10 @@ spec:
|
|||||||
runAfter:
|
runAfter:
|
||||||
- build-image
|
- build-image
|
||||||
params:
|
params:
|
||||||
|
- name: command
|
||||||
|
value: ["$(params.command[*])"]
|
||||||
- name: args
|
- name: args
|
||||||
value:
|
value: ["$(params.args[*])"]
|
||||||
[
|
|
||||||
--no-default-features,
|
|
||||||
--features,
|
|
||||||
"compare,wasm_test",
|
|
||||||
--no-fail-fast,
|
|
||||||
--lib,
|
|
||||||
--test,
|
|
||||||
test_loader,
|
|
||||||
]
|
|
||||||
- name: docker-image
|
- name: docker-image
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
||||||
finally:
|
finally:
|
||||||
@@ -212,3 +212,7 @@ spec:
|
|||||||
value: docker/organic_test/
|
value: docker/organic_test/
|
||||||
- name: path-to-dockerfile
|
- name: path-to-dockerfile
|
||||||
value: docker/organic_test/Dockerfile
|
value: docker/organic_test/Dockerfile
|
||||||
|
- name: command
|
||||||
|
value: [cargo, test]
|
||||||
|
- name: args
|
||||||
|
value: [--lib, --test, test_loader]
|
||||||
|
|||||||
@@ -14,6 +14,14 @@ spec:
|
|||||||
- name: path-to-dockerfile
|
- name: path-to-dockerfile
|
||||||
description: The path to the Dockerfile
|
description: The path to the Dockerfile
|
||||||
type: string
|
type: string
|
||||||
|
- name: rustfmt-command
|
||||||
|
type: array
|
||||||
|
description: Command to run rustfmt.
|
||||||
|
default: []
|
||||||
|
- name: rustfmt-args
|
||||||
|
type: array
|
||||||
|
description: Arguments passed to rustfmt.
|
||||||
|
default: []
|
||||||
- name: GIT_USER_NAME
|
- name: GIT_USER_NAME
|
||||||
description: The username for git
|
description: The username for git
|
||||||
type: string
|
type: string
|
||||||
@@ -111,6 +119,10 @@ spec:
|
|||||||
runAfter:
|
runAfter:
|
||||||
- build-image
|
- build-image
|
||||||
params:
|
params:
|
||||||
|
- name: command
|
||||||
|
value: ["$(params.rustfmt-command[*])"]
|
||||||
|
- name: args
|
||||||
|
value: ["$(params.rustfmt-args[*])"]
|
||||||
- name: docker-image
|
- name: docker-image
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
||||||
- name: cargo-fix
|
- name: cargo-fix
|
||||||
@@ -127,7 +139,7 @@ spec:
|
|||||||
- name: command
|
- name: command
|
||||||
value: ["cargo", "fix"]
|
value: ["cargo", "fix"]
|
||||||
- name: args
|
- name: args
|
||||||
value: ["--all-targets", "--all-features", "--allow-dirty"]
|
value: ["--allow-dirty"]
|
||||||
- name: docker-image
|
- name: docker-image
|
||||||
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
value: "$(params.image-name):$(tasks.fetch-repository.results.commit)"
|
||||||
- name: commit-changes
|
- name: commit-changes
|
||||||
@@ -228,3 +240,7 @@ spec:
|
|||||||
value: docker/cargo_fmt/
|
value: docker/cargo_fmt/
|
||||||
- name: path-to-dockerfile
|
- name: path-to-dockerfile
|
||||||
value: docker/cargo_fmt/Dockerfile
|
value: docker/cargo_fmt/Dockerfile
|
||||||
|
- name: command
|
||||||
|
value: [cargo, fmt]
|
||||||
|
- name: args
|
||||||
|
value: []
|
||||||
|
|||||||
@@ -16,13 +16,6 @@ spec:
|
|||||||
skip_branches:
|
skip_branches:
|
||||||
# We already run on every commit, so running when the semver tags get pushed is causing needless double-processing.
|
# We already run on every commit, so running when the semver tags get pushed is causing needless double-processing.
|
||||||
- "^v[0-9]+\\.[0-9]+\\.[0-9]+$"
|
- "^v[0-9]+\\.[0-9]+\\.[0-9]+$"
|
||||||
- name: rust-foreign-document-test
|
|
||||||
source: "pipeline-foreign-document-test.yaml"
|
|
||||||
# Override https-based url from lighthouse events.
|
|
||||||
clone_uri: "git@code.fizz.buzz:talexander/organic.git"
|
|
||||||
skip_branches:
|
|
||||||
# We already run on every commit, so running when the semver tags get pushed is causing needless double-processing.
|
|
||||||
- "^v[0-9]+\\.[0-9]+\\.[0-9]+$"
|
|
||||||
- name: rust-build
|
- name: rust-build
|
||||||
source: "pipeline-rust-build.yaml"
|
source: "pipeline-rust-build.yaml"
|
||||||
# Override https-based url from lighthouse events.
|
# Override https-based url from lighthouse events.
|
||||||
@@ -30,10 +23,3 @@ spec:
|
|||||||
skip_branches:
|
skip_branches:
|
||||||
# We already run on every commit, so running when the semver tags get pushed is causing needless double-processing.
|
# We already run on every commit, so running when the semver tags get pushed is causing needless double-processing.
|
||||||
- "^v[0-9]+\\.[0-9]+\\.[0-9]+$"
|
- "^v[0-9]+\\.[0-9]+\\.[0-9]+$"
|
||||||
- name: clippy
|
|
||||||
source: "pipeline-clippy.yaml"
|
|
||||||
# Override https-based url from lighthouse events.
|
|
||||||
clone_uri: "git@code.fizz.buzz:talexander/organic.git"
|
|
||||||
skip_branches:
|
|
||||||
# We already run on every commit, so running when the semver tags get pushed is causing needless double-processing.
|
|
||||||
- "^v[0-9]+\\.[0-9]+\\.[0-9]+$"
|
|
||||||
|
|||||||
64
Cargo.toml
64
Cargo.toml
@@ -1,8 +1,6 @@
|
|||||||
# cargo-features = ["profile-rustflags"]
|
|
||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "organic"
|
name = "organic"
|
||||||
version = "0.1.14"
|
version = "0.1.2"
|
||||||
authors = ["Tom Alexander <tom@fizz.buzz>"]
|
authors = ["Tom Alexander <tom@fizz.buzz>"]
|
||||||
description = "An org-mode parser."
|
description = "An org-mode parser."
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
@@ -15,7 +13,8 @@ resolver = "2"
|
|||||||
include = [
|
include = [
|
||||||
"LICENSE",
|
"LICENSE",
|
||||||
"**/*.rs",
|
"**/*.rs",
|
||||||
"Cargo.toml"
|
"Cargo.toml",
|
||||||
|
"tests/*"
|
||||||
]
|
]
|
||||||
|
|
||||||
[lib]
|
[lib]
|
||||||
@@ -23,81 +22,34 @@ name = "organic"
|
|||||||
path = "src/lib.rs"
|
path = "src/lib.rs"
|
||||||
|
|
||||||
[[bin]]
|
[[bin]]
|
||||||
# This bin exists for development purposes only. The real target of this crate is the library.
|
# This bin exists for development purposes only. The real target of this crate is the library.
|
||||||
name = "parse"
|
name = "compare"
|
||||||
path = "src/main.rs"
|
path = "src/main.rs"
|
||||||
|
|
||||||
[[bin]]
|
|
||||||
# This bin exists for development purposes only. The real target of this crate is the library.
|
|
||||||
name = "compare"
|
|
||||||
path = "src/bin_compare.rs"
|
|
||||||
required-features = ["compare"]
|
|
||||||
|
|
||||||
[[bin]]
|
|
||||||
# This bin exists for development purposes only. The real target of this crate is the library.
|
|
||||||
name = "foreign_document_test"
|
|
||||||
path = "src/bin_foreign_document_test.rs"
|
|
||||||
required-features = ["foreign_document_test"]
|
|
||||||
|
|
||||||
[[bin]]
|
|
||||||
name = "wasm"
|
|
||||||
path = "src/bin_wasm.rs"
|
|
||||||
required-features = ["wasm"]
|
|
||||||
|
|
||||||
[[bin]]
|
|
||||||
# This bin exists for development purposes only. The real target of this crate is the library.
|
|
||||||
name = "wasm_test"
|
|
||||||
path = "src/bin_wasm_test.rs"
|
|
||||||
required-features = ["wasm_test"]
|
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
futures = { version = "0.3.28", optional = true }
|
|
||||||
nom = "7.1.1"
|
nom = "7.1.1"
|
||||||
opentelemetry = { version = "0.20.0", optional = true, default-features = false, features = ["trace", "rt-tokio"] }
|
opentelemetry = { version = "0.20.0", optional = true, default-features = false, features = ["trace", "rt-tokio"] }
|
||||||
opentelemetry-otlp = { version = "0.13.0", optional = true }
|
opentelemetry-otlp = { version = "0.13.0", optional = true }
|
||||||
opentelemetry-semantic-conventions = { version = "0.12.0", optional = true }
|
opentelemetry-semantic-conventions = { version = "0.12.0", optional = true }
|
||||||
serde = { version = "1.0.193", optional = true, features = ["derive"] }
|
|
||||||
serde-wasm-bindgen = { version = "0.6.3", optional = true }
|
|
||||||
serde_json = { version = "1.0.108", optional = true }
|
|
||||||
tokio = { version = "1.30.0", optional = true, default-features = false, features = ["rt", "rt-multi-thread"] }
|
tokio = { version = "1.30.0", optional = true, default-features = false, features = ["rt", "rt-multi-thread"] }
|
||||||
tracing = { version = "0.1.37", optional = true }
|
tracing = { version = "0.1.37", optional = true }
|
||||||
tracing-opentelemetry = { version = "0.20.0", optional = true }
|
tracing-opentelemetry = { version = "0.20.0", optional = true }
|
||||||
tracing-subscriber = { version = "0.3.17", optional = true, features = ["env-filter"] }
|
tracing-subscriber = { version = "0.3.17", optional = true, features = ["env-filter"] }
|
||||||
walkdir = { version = "2.3.3", optional = true }
|
|
||||||
wasm-bindgen = { version = "0.2.89", optional = true }
|
|
||||||
|
|
||||||
[build-dependencies]
|
[build-dependencies]
|
||||||
walkdir = "2.3.3"
|
walkdir = "2.3.3"
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
default = []
|
default = ["compare"]
|
||||||
compare = ["tokio/process", "tokio/macros"]
|
compare = []
|
||||||
foreign_document_test = ["compare", "dep:futures", "tokio/sync", "dep:walkdir", "tokio/process"]
|
|
||||||
tracing = ["dep:opentelemetry", "dep:opentelemetry-otlp", "dep:opentelemetry-semantic-conventions", "dep:tokio", "dep:tracing", "dep:tracing-opentelemetry", "dep:tracing-subscriber"]
|
tracing = ["dep:opentelemetry", "dep:opentelemetry-otlp", "dep:opentelemetry-semantic-conventions", "dep:tokio", "dep:tracing", "dep:tracing-opentelemetry", "dep:tracing-subscriber"]
|
||||||
event_count = []
|
|
||||||
wasm = ["dep:serde", "dep:wasm-bindgen", "dep:serde-wasm-bindgen"]
|
|
||||||
wasm_test = ["wasm", "dep:serde_json", "tokio/process", "tokio/macros"]
|
|
||||||
|
|
||||||
# Optimized build for any sort of release.
|
|
||||||
[profile.release-lto]
|
[profile.release-lto]
|
||||||
inherits = "release"
|
inherits = "release"
|
||||||
lto = true
|
lto = true
|
||||||
strip = "symbols"
|
strip = "symbols"
|
||||||
|
|
||||||
# Optimized build for local execution.
|
|
||||||
# [profile.native]
|
|
||||||
# inherits = "release"
|
|
||||||
# lto = true
|
|
||||||
# strip = "symbols"
|
|
||||||
# rustflags = ["-C", "target-cpu=native"]
|
|
||||||
|
|
||||||
# Profile for performance testing with the "perf" tool. Notably keeps debug enabled and does not strip symbols to make reading the perf output easier.
|
|
||||||
[profile.perf]
|
[profile.perf]
|
||||||
inherits = "release"
|
inherits = "release"
|
||||||
lto = true
|
lto = true
|
||||||
debug = true
|
debug = true
|
||||||
|
|
||||||
[profile.wasm]
|
|
||||||
inherits = "release"
|
|
||||||
lto = true
|
|
||||||
strip = true
|
|
||||||
|
|||||||
51
Makefile
51
Makefile
@@ -29,59 +29,18 @@ build:
|
|||||||
release:
|
release:
|
||||||
> cargo build --release $(RELEASEFLAGS)
|
> cargo build --release $(RELEASEFLAGS)
|
||||||
|
|
||||||
.PHONY: wasm
|
|
||||||
wasm:
|
|
||||||
> cargo build --target=wasm32-unknown-unknown --profile wasm --bin wasm --features wasm
|
|
||||||
> wasm-bindgen --target web --out-dir target/wasm32-unknown-unknown/js target/wasm32-unknown-unknown/wasm/wasm.wasm
|
|
||||||
|
|
||||||
.PHONY: clean
|
.PHONY: clean
|
||||||
clean:
|
clean:
|
||||||
> cargo clean
|
> cargo clean
|
||||||
|
|
||||||
.PHONY: format
|
|
||||||
format:
|
|
||||||
> $(MAKE) -C docker/cargo_fmt run
|
|
||||||
|
|
||||||
.PHONY: dockerclippy
|
|
||||||
dockerclippy:
|
|
||||||
> $(MAKE) -C docker/organic_clippy run
|
|
||||||
|
|
||||||
.PHONY: clippy
|
|
||||||
clippy:
|
|
||||||
> cargo clippy --no-deps --all-targets --all-features -- -D warnings
|
|
||||||
|
|
||||||
.PHONY: test
|
.PHONY: test
|
||||||
test:
|
test:
|
||||||
> cargo test --no-default-features --features compare --no-fail-fast --lib --test test_loader -- --test-threads $(TESTJOBS)
|
> cargo test --no-fail-fast --lib --test test_loader -- --test-threads $(TESTJOBS)
|
||||||
|
|
||||||
.PHONY: doc
|
|
||||||
doc:
|
|
||||||
> cargo doc --no-deps --open --lib --release --all-features
|
|
||||||
|
|
||||||
.PHONY: dockertest
|
.PHONY: dockertest
|
||||||
dockertest:
|
dockertest:
|
||||||
> $(MAKE) -C docker/organic_test
|
> $(MAKE) -C docker/organic_test
|
||||||
> docker run --init --rm -i -t --read-only -v "$$(readlink -f ./):/source:ro" --mount type=tmpfs,destination=/tmp --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target -w /source organic-test --no-default-features --features compare --no-fail-fast --lib --test test_loader -- --test-threads $(TESTJOBS)
|
> docker run --init --rm -i -t -v "$$(readlink -f ./):/source:ro" --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target -w /source organic-test cargo test --no-fail-fast --lib --test test_loader -- --test-threads $(TESTJOBS)
|
||||||
|
|
||||||
.PHONY: dockerwasmtest
|
|
||||||
dockerwasmtest:
|
|
||||||
> $(MAKE) -C docker/organic_test
|
|
||||||
> docker run --init --rm -i -t --read-only -v "$$(readlink -f ./):/source:ro" --mount type=tmpfs,destination=/tmp --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target -w /source organic-test --no-default-features --features compare,wasm_test --no-fail-fast --lib --test test_loader autogen_wasm_ -- --test-threads $(TESTJOBS)
|
|
||||||
|
|
||||||
.PHONY: buildtest
|
|
||||||
buildtest:
|
|
||||||
> cargo build --no-default-features
|
|
||||||
> cargo build --no-default-features --features compare
|
|
||||||
> cargo build --no-default-features --features tracing
|
|
||||||
> cargo build --no-default-features --features compare,tracing
|
|
||||||
> cargo build --no-default-features --features compare,foreign_document_test
|
|
||||||
> cargo build --no-default-features --features compare,tracing,foreign_document_test
|
|
||||||
> cargo build --target wasm32-unknown-unknown --profile wasm --bin wasm --no-default-features --features wasm
|
|
||||||
> cargo build --bin wasm_test --no-default-features --features wasm_test
|
|
||||||
|
|
||||||
.PHONY: foreign_document_test
|
|
||||||
foreign_document_test:
|
|
||||||
> $(MAKE) -C docker/organic_test run_foreign_document_test
|
|
||||||
|
|
||||||
.PHONY: dockerclean
|
.PHONY: dockerclean
|
||||||
dockerclean:
|
dockerclean:
|
||||||
@@ -90,18 +49,18 @@ dockerclean:
|
|||||||
|
|
||||||
.PHONY: integrationtest
|
.PHONY: integrationtest
|
||||||
integrationtest:
|
integrationtest:
|
||||||
> cargo test --no-default-features --features compare --no-fail-fast --test test_loader -- --test-threads $(TESTJOBS)
|
> cargo test --no-fail-fast --test test_loader -- --test-threads $(TESTJOBS)
|
||||||
|
|
||||||
.PHONY: unittest
|
.PHONY: unittest
|
||||||
unittest:
|
unittest:
|
||||||
> cargo test --no-default-features --lib -- --test-threads $(TESTJOBS)
|
> cargo test --lib -- --test-threads $(TESTJOBS)
|
||||||
|
|
||||||
.PHONY: jaeger
|
.PHONY: jaeger
|
||||||
jaeger:
|
jaeger:
|
||||||
# 4317 for OTLP gRPC, 4318 for OTLP HTTP. We currently use gRPC but I forward both ports regardless.
|
# 4317 for OTLP gRPC, 4318 for OTLP HTTP. We currently use gRPC but I forward both ports regardless.
|
||||||
#
|
#
|
||||||
# These flags didn't help even though they seem like they would: --collector.queue-size=20000 --collector.num-workers=100
|
# These flags didn't help even though they seem like they would: --collector.queue-size=20000 --collector.num-workers=100
|
||||||
> docker run -d --rm --name organicdocker --read-only -p 4317:4317 -p 4318:4318 -p 16686:16686 -e COLLECTOR_OTLP_ENABLED=true jaegertracing/all-in-one:1.47 --collector.grpc-server.max-message-size=20000000 --collector.otlp.grpc.max-message-size=20000000
|
> docker run -d --rm --name organicdocker -p 4317:4317 -p 4318:4318 -p 16686:16686 -e COLLECTOR_OTLP_ENABLED=true jaegertracing/all-in-one:1.47 --collector.grpc-server.max-message-size=20000000 --collector.otlp.grpc.max-message-size=20000000
|
||||||
|
|
||||||
.PHONY: jaegerweb
|
.PHONY: jaegerweb
|
||||||
jaegerweb:
|
jaegerweb:
|
||||||
|
|||||||
77
README.md
77
README.md
@@ -2,83 +2,12 @@
|
|||||||
|
|
||||||
Organic is an emacs-less implementation of an [org-mode](https://orgmode.org/) parser.
|
Organic is an emacs-less implementation of an [org-mode](https://orgmode.org/) parser.
|
||||||
|
|
||||||
|
|
||||||
## Project Status
|
## Project Status
|
||||||
|
|
||||||
This project is still under HEAVY development. While the version remains v0.1.x the API will be changing often. Once we hit v0.2.x we will start following semver.
|
This project is a personal learning project to grow my experience in [rust](https://www.rust-lang.org/). It is under development and at this time I would not recommend anyone use this code. The goal is to turn this into a project others can use, at which point more information will appear in this README.
|
||||||
|
|
||||||
Currently, Organic parses most documents the same as the official org-mode parser. Most of the development right now is finding documents where the parsers differ and fixing those issues.
|
|
||||||
|
|
||||||
### Project Goals
|
|
||||||
- We aim to provide perfect parity with the emacs org-mode parser. In that regard, any document that parses differently between Emacs and Organic is considered a bug.
|
|
||||||
- The parser should have minimal dependencies. This should reduce effort w.r.t.: security audits, legal compliance, portability.
|
|
||||||
- The parser should be usable everywhere. In the interest of getting org-mode used in as many places as possible, this parser should be usable by everyone everywhere. This means:
|
|
||||||
- It must have a permissive license.
|
|
||||||
- We will investigate compiling to WASM. This is an important goal of the project and will definitely happen, but only after the parser has a more stable API.
|
|
||||||
- We will investigate compiling to a C library for native linking to other code. This is more of a maybe-goal for the project.
|
|
||||||
### Project Non-Goals
|
|
||||||
- This project will not include an elisp engine since that would drastically increase the complexity of the code. Any features requiring an elisp engine will not be implemented (for example, Emacs supports embedded eval expressions in documents but this parser will never support that).
|
|
||||||
- This project is exclusively an org-mode **parser**. This limits its scope to roughly the output of `(org-element-parse-buffer)`. It will not render org-mode documents in other formats like HTML or LaTeX.
|
|
||||||
### Project Maybe-Goals
|
|
||||||
- table.el support. Currently we support org-mode tables but org-mode also allows table.el tables. So far, their use in org-mode documents seems rather uncommon so this is a low-priority feature.
|
|
||||||
- Document editing support. I do not anticipate any advanced editing features to make editing ergonomic, but it should be relatively easy to be able to parse an org-mode document and serialize it back into org-mode. This would enable cool features to be built on top of the library like auto-formatters. To accomplish this feature, We'd have to capture all of the various separators and whitespace that we are currently simply throwing away. This would add many additional fields to the parsed structs and it would add more noise to the parsers themselves, so I do not want to approach this feature until the parser is more complete since it would make modifications and refactoring more difficult.
|
|
||||||
### Supported Versions
|
|
||||||
This project targets the version of Emacs and Org-mode that are built into the [organic-test docker image](docker/organic_test/Dockerfile). This is newer than the version of Org-mode that shipped with Emacs 29.1. The parser itself does not depend on Emacs or Org-mode though, so this only matters for development purposes when running the automated tests that compare against upstream Org-mode.
|
|
||||||
|
|
||||||
## Using this library
|
|
||||||
TODO: Add section on using Organic as a library (which is the intended use for this project). This will be added when we have a bit more API stability since currently the library is under heavy development.
|
|
||||||
|
|
||||||
## Development
|
|
||||||
|
|
||||||
### The parse binary
|
|
||||||
This program takes org-mode input either streamed in on stdin or as paths to files passed in as arguments. It then parses them using Organic and dumps the result to stdout. This program is intended solely as a development tool. Examples:
|
|
||||||
```bash
|
|
||||||
cat /foo/bar.org | cargo run --bin parse
|
|
||||||
```
|
|
||||||
```bash
|
|
||||||
cargo build --profile release-lto
|
|
||||||
./target/release-lto/parse /foo/bar.org /lorem/ipsum.org
|
|
||||||
```
|
|
||||||
|
|
||||||
### The compare binary
|
|
||||||
This program takes org-mode input either streamed in on stdin or as paths to files passed in as arguments. It then parses them using Organic and the official Emacs Org-mode parser and compares the parse result. This program is intended solely as a development tool. Since org-mode is a moving target, it is recommended that you run this through docker since we pin the version of org-mode to a specific revision. Examples:
|
|
||||||
```bash
|
|
||||||
cat /foo/bar.org | ./scripts/run_docker_compare.bash
|
|
||||||
```
|
|
||||||
```bash
|
|
||||||
./scripts/run_docker_compare.bash /foo/bar.org /lorem/ipsum.org
|
|
||||||
```
|
|
||||||
|
|
||||||
Not recommended since it is not through docker:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
cat /foo/bar.org | cargo run --features compare --bin compare
|
|
||||||
```
|
|
||||||
```bash
|
|
||||||
cargo build --profile release-lto --features compare
|
|
||||||
./target/release-lto/compare /foo/bar.org /lorem/ipsum.org
|
|
||||||
```
|
|
||||||
|
|
||||||
## Running the tests
|
|
||||||
There are three levels of tests for this repository: the standard tests, the autogenerated tests, and the foreign document tests.
|
|
||||||
|
|
||||||
### The standard tests
|
|
||||||
These are regular hand-written rust tests. These can be run with:
|
|
||||||
```bash
|
|
||||||
make unittest
|
|
||||||
```
|
|
||||||
|
|
||||||
### The auto-generated tests
|
|
||||||
These tests are automatically generated from the files in the `org_mode_samples` directory and they are still integrated with the rust/cargo testing framework. For each org-mode document in that folder, a test is generated that will parse the document with both Organic and the official Emacs Org-mode parser and then it will compare the parse results. Any deviation is considered a failure. Since org-mode is a moving target, it is recommended that you run these tests inside docker since the `organic-test` docker image is pinned to a specific revision of org-mode. These can be run with:
|
|
||||||
```bash
|
|
||||||
make dockertest
|
|
||||||
```
|
|
||||||
|
|
||||||
### The foreign document tests
|
|
||||||
These tests function the same as the auto-generated tests except they are **not** integrated with the rust/cargo testing framework and they involve comparing the parse of org-mode documents that live outside this repository. This allows us to test against a far greater variety of org-mode input documents without pulling massive sets of org-mode documents into this repository. The recommended way to run these tests is still through docker because it pins org-mode and the test documents to specific git revisions. These can be run with:
|
|
||||||
```bash
|
|
||||||
make foreign_document_test
|
|
||||||
```
|
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
This project is released under the public-domain-equivalent [0BSD license](https://www.tldrlegal.com/license/bsd-0-clause-license), however, this project has a couple permissively licensed non-public-domain-equivalent dependencies which require their copyright notices and/or license texts to be included. I am not a lawyer and this is not legal advice but it is my layperson's understanding that if you distribute a binary statically linking this library, you will need to abide by their terms since their code will also be linked in your binary.
|
This project is released under the public-domain-equivalent [0BSD license](https://www.tldrlegal.com/license/bsd-0-clause-license). This license puts no restrictions on the use of this code (you do not even have to include the copyright notice or license text when using it). HOWEVER, this project has a couple permissively licensed dependencies which do require their copyright notices and/or license texts to be included. I am not a lawyer and this is not legal advice but it is my layperson's understanding that if you distribute a binary with this library linked in, you will need to abide by their terms since their code will also be linked in your binary. I try to keep the dependencies to a minimum and the most restrictive dependency I will ever include is a permissively licensed one.
|
||||||
|
|||||||
51
build.rs
51
build.rs
@@ -1,23 +1,16 @@
|
|||||||
#[cfg(feature = "compare")]
|
|
||||||
use std::env;
|
use std::env;
|
||||||
#[cfg(feature = "compare")]
|
|
||||||
use std::fs::File;
|
use std::fs::File;
|
||||||
#[cfg(feature = "compare")]
|
|
||||||
use std::io::Write;
|
use std::io::Write;
|
||||||
#[cfg(feature = "compare")]
|
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
|
|
||||||
#[cfg(feature = "compare")]
|
|
||||||
use walkdir::WalkDir;
|
use walkdir::WalkDir;
|
||||||
|
|
||||||
#[cfg(feature = "compare")]
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let out_dir = env::var("OUT_DIR").unwrap();
|
let out_dir = env::var("OUT_DIR").unwrap();
|
||||||
let destination = Path::new(&out_dir).join("tests.rs");
|
let destination = Path::new(&out_dir).join("tests.rs");
|
||||||
let mut test_file = File::create(destination).unwrap();
|
let mut test_file = File::create(&destination).unwrap();
|
||||||
|
|
||||||
// Re-generate the tests if any org-mode files change
|
write_header(&mut test_file);
|
||||||
println!("cargo:rerun-if-changed=org_mode_samples");
|
|
||||||
|
|
||||||
let test_files = WalkDir::new("org_mode_samples")
|
let test_files = WalkDir::new("org_mode_samples")
|
||||||
.into_iter()
|
.into_iter()
|
||||||
@@ -38,10 +31,6 @@ fn main() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(feature = "compare"))]
|
|
||||||
fn main() {}
|
|
||||||
|
|
||||||
#[cfg(feature = "compare")]
|
|
||||||
fn write_test(test_file: &mut File, test: &walkdir::DirEntry) {
|
fn write_test(test_file: &mut File, test: &walkdir::DirEntry) {
|
||||||
let test_name = test
|
let test_name = test
|
||||||
.path()
|
.path()
|
||||||
@@ -51,21 +40,41 @@ fn write_test(test_file: &mut File, test: &walkdir::DirEntry) {
|
|||||||
.to_lowercase()
|
.to_lowercase()
|
||||||
.strip_suffix(".org")
|
.strip_suffix(".org")
|
||||||
.expect("Should have .org extension")
|
.expect("Should have .org extension")
|
||||||
.replace('/', "_");
|
.replace("/", "_");
|
||||||
|
let test_name = format!("autogen_{}", test_name);
|
||||||
|
|
||||||
|
if let Some(_reason) = is_expect_fail(test_name.as_str()) {
|
||||||
|
write!(test_file, "#[ignore]\n").unwrap();
|
||||||
|
}
|
||||||
write!(
|
write!(
|
||||||
test_file,
|
test_file,
|
||||||
include_str!("./tests/test_template"),
|
include_str!("./tests/test_template"),
|
||||||
name = test_name,
|
name = test_name,
|
||||||
path = test.path().display(),
|
path = test.path().display()
|
||||||
expect_fail = is_expect_fail(test_name.as_str())
|
|
||||||
.map(|_| "#[ignore]\n")
|
|
||||||
.unwrap_or("")
|
|
||||||
)
|
)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(feature = "compare")]
|
fn write_header(test_file: &mut File) {
|
||||||
fn is_expect_fail(_name: &str) -> Option<&str> {
|
write!(
|
||||||
None
|
test_file,
|
||||||
|
r#"
|
||||||
|
#[feature(exit_status_error)]
|
||||||
|
use organic::compare_document;
|
||||||
|
use organic::parser::document;
|
||||||
|
use organic::emacs_parse_org_document;
|
||||||
|
use organic::parser::sexp::sexp_with_padding;
|
||||||
|
|
||||||
|
"#
|
||||||
|
)
|
||||||
|
.unwrap();
|
||||||
|
}
|
||||||
|
|
||||||
|
fn is_expect_fail(name: &str) -> Option<&str> {
|
||||||
|
match name {
|
||||||
|
"autogen_greater_element_drawer_drawer_with_headline_inside" => Some("Apparently lines with :end: become their own paragraph. This odd behavior needs to be investigated more."),
|
||||||
|
"autogen_element_container_priority_footnote_definition_dynamic_block" => Some("Apparently broken begin lines become their own paragraph."),
|
||||||
|
"autogen_lesser_element_paragraphs_paragraph_with_backslash_line_breaks" => Some("The text we're getting out of the parse tree is already processed to remove line breaks, so our comparison needs to take that into account."),
|
||||||
|
_ => None,
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ all: build push
|
|||||||
|
|
||||||
.PHONY: build
|
.PHONY: build
|
||||||
build:
|
build:
|
||||||
docker build -t $(IMAGE_NAME) -f Dockerfile .
|
docker build -t $(IMAGE_NAME) -f Dockerfile ../../
|
||||||
|
|
||||||
.PHONY: push
|
.PHONY: push
|
||||||
push:
|
push:
|
||||||
@@ -26,11 +26,10 @@ else
|
|||||||
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# NOTE: This target will write to folders underneath the git-root
|
|
||||||
.PHONY: run
|
.PHONY: run
|
||||||
run: build
|
run:
|
||||||
docker run --rm --init --read-only --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source" --workdir=/source $(IMAGE_NAME)
|
docker run --rm -i -t $(IMAGE_NAME)
|
||||||
|
|
||||||
.PHONY: shell
|
.PHONY: shell
|
||||||
shell: build
|
shell:
|
||||||
docker run --rm -i -t --entrypoint /bin/sh --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source" --workdir=/source $(IMAGE_NAME)
|
docker run --rm -i -t --entrypoint /bin/bash $(IMAGE_NAME)
|
||||||
|
|||||||
@@ -2,6 +2,3 @@ FROM rustlang/rust:nightly-alpine3.17
|
|||||||
|
|
||||||
RUN apk add --no-cache musl-dev
|
RUN apk add --no-cache musl-dev
|
||||||
RUN cargo install --locked --no-default-features --features ci-autoclean cargo-cache
|
RUN cargo install --locked --no-default-features --features ci-autoclean cargo-cache
|
||||||
RUN rustup target add wasm32-unknown-unknown
|
|
||||||
|
|
||||||
ENTRYPOINT ["cargo", "build"]
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ all: build push
|
|||||||
|
|
||||||
.PHONY: build
|
.PHONY: build
|
||||||
build:
|
build:
|
||||||
docker build -t $(IMAGE_NAME) -f Dockerfile .
|
docker build -t $(IMAGE_NAME) -f Dockerfile ../../
|
||||||
|
|
||||||
.PHONY: push
|
.PHONY: push
|
||||||
push:
|
push:
|
||||||
@@ -25,13 +25,11 @@ ifdef REMOTE_REPO
|
|||||||
else
|
else
|
||||||
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
||||||
endif
|
endif
|
||||||
docker volume rm cargo-cache
|
|
||||||
|
|
||||||
# NOTE: This target will write to folders underneath the git-root
|
|
||||||
.PHONY: run
|
.PHONY: run
|
||||||
run: build
|
run:
|
||||||
docker run --rm --init --read-only --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry $(IMAGE_NAME)
|
docker run --rm -i -t $(IMAGE_NAME)
|
||||||
|
|
||||||
.PHONY: shell
|
.PHONY: shell
|
||||||
shell: build
|
shell:
|
||||||
docker run --rm -i -t --entrypoint /bin/sh --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry $(IMAGE_NAME)
|
docker run --rm -i -t --entrypoint /bin/bash $(IMAGE_NAME)
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
FROM rustlang/rust:nightly-alpine3.17
|
|
||||||
|
|
||||||
RUN apk add --no-cache musl-dev
|
|
||||||
|
|
||||||
ENTRYPOINT ["cargo", "clippy", "--no-deps", "--all-targets", "--all-features", "--", "-D", "warnings"]
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
IMAGE_NAME:=organic-clippy
|
|
||||||
# REMOTE_REPO:=harbor.fizz.buzz/private
|
|
||||||
|
|
||||||
.PHONY: all
|
|
||||||
all: build push
|
|
||||||
|
|
||||||
.PHONY: build
|
|
||||||
build:
|
|
||||||
docker build -t $(IMAGE_NAME) -f Dockerfile .
|
|
||||||
|
|
||||||
.PHONY: push
|
|
||||||
push:
|
|
||||||
ifdef REMOTE_REPO
|
|
||||||
docker tag $(IMAGE_NAME) $(REMOTE_REPO)/$(IMAGE_NAME)
|
|
||||||
docker push $(REMOTE_REPO)/$(IMAGE_NAME)
|
|
||||||
else
|
|
||||||
@echo "REMOTE_REPO not defined, not pushing to a remote repo."
|
|
||||||
endif
|
|
||||||
|
|
||||||
.PHONY: clean
|
|
||||||
clean:
|
|
||||||
docker rmi $(IMAGE_NAME)
|
|
||||||
ifdef REMOTE_REPO
|
|
||||||
docker rmi $(REMOTE_REPO)/$(IMAGE_NAME)
|
|
||||||
else
|
|
||||||
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
|
||||||
endif
|
|
||||||
docker volume rm rust-cache cargo-cache
|
|
||||||
|
|
||||||
# NOTE: This target will write to folders underneath the git-root
|
|
||||||
.PHONY: run
|
|
||||||
run: build
|
|
||||||
docker run --rm --init -t --read-only --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source:ro" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target $(IMAGE_NAME)
|
|
||||||
|
|
||||||
.PHONY: shell
|
|
||||||
shell: build
|
|
||||||
docker run --rm -i -t --entrypoint /bin/sh --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source:ro" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target $(IMAGE_NAME)
|
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
FROM alpine:3.17 AS build
|
FROM alpine:3.17 AS build
|
||||||
RUN apk add --no-cache build-base musl-dev git autoconf make texinfo gnutls-dev ncurses-dev gawk libgccjit-dev
|
RUN apk add --no-cache build-base musl-dev git autoconf make texinfo gnutls-dev ncurses-dev gawk
|
||||||
|
|
||||||
|
|
||||||
FROM build AS build-emacs
|
FROM build AS build-emacs
|
||||||
@@ -8,13 +8,13 @@ RUN git clone --depth 1 --branch $EMACS_VERSION https://git.savannah.gnu.org/git
|
|||||||
WORKDIR /root/emacs
|
WORKDIR /root/emacs
|
||||||
RUN mkdir /root/dist
|
RUN mkdir /root/dist
|
||||||
RUN ./autogen.sh
|
RUN ./autogen.sh
|
||||||
RUN ./configure --prefix /usr --without-x --without-sound --with-native-compilation=aot
|
RUN ./configure --prefix /usr --without-x --without-sound
|
||||||
RUN make
|
RUN make
|
||||||
RUN make DESTDIR="/root/dist" install
|
RUN make DESTDIR="/root/dist" install
|
||||||
|
|
||||||
|
|
||||||
FROM build AS build-org-mode
|
FROM build AS build-org-mode
|
||||||
ARG ORG_VERSION=abf5156096c06ee5aa05795c3dc5a065f76ada97
|
ARG ORG_VERSION=7bdec435ff5d86220d13c431e799c5ed44a57da1
|
||||||
COPY --from=build-emacs /root/dist/ /
|
COPY --from=build-emacs /root/dist/ /
|
||||||
RUN mkdir /root/dist
|
RUN mkdir /root/dist
|
||||||
# Savannah does not allow fetching specific revisions, so we're going to have to put unnecessary load on their server by cloning main and then checking out the revision we want.
|
# Savannah does not allow fetching specific revisions, so we're going to have to put unnecessary load on their server by cloning main and then checking out the revision we want.
|
||||||
@@ -25,88 +25,8 @@ RUN make compile
|
|||||||
RUN make DESTDIR="/root/dist" install
|
RUN make DESTDIR="/root/dist" install
|
||||||
|
|
||||||
|
|
||||||
FROM rustlang/rust:nightly-alpine3.17 AS tester
|
FROM rustlang/rust:nightly-alpine3.17
|
||||||
ENV LANG=en_US.UTF-8
|
RUN apk add --no-cache musl-dev ncurses gnutls
|
||||||
RUN apk add --no-cache musl-dev ncurses gnutls libgccjit
|
|
||||||
RUN cargo install --locked --no-default-features --features ci-autoclean cargo-cache
|
RUN cargo install --locked --no-default-features --features ci-autoclean cargo-cache
|
||||||
COPY --from=build-emacs /root/dist/ /
|
COPY --from=build-emacs /root/dist/ /
|
||||||
COPY --from=build-org-mode /root/dist/ /
|
COPY --from=build-org-mode /root/dist/ /
|
||||||
|
|
||||||
ENTRYPOINT ["cargo", "test"]
|
|
||||||
|
|
||||||
|
|
||||||
FROM build as foreign-document-gather
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_DOT_FILES_VERSION=1b54fe75d74670dc7bcbb6b01ea560c45528c628
|
|
||||||
ARG HOWARD_ABRAMS_DOT_FILES_PATH=/foreign_documents/howardabrams/dot-files
|
|
||||||
ARG HOWARD_ABRAMS_DOT_FILES_REPO=https://github.com/howardabrams/dot-files.git
|
|
||||||
RUN mkdir /foreign_documents
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_DOT_FILES_PATH && git -C $HOWARD_ABRAMS_DOT_FILES_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_DOT_FILES_PATH remote add origin $HOWARD_ABRAMS_DOT_FILES_REPO && git -C $HOWARD_ABRAMS_DOT_FILES_PATH fetch origin $HOWARD_ABRAMS_DOT_FILES_VERSION && git -C $HOWARD_ABRAMS_DOT_FILES_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_HAMACS_VERSION=da51188cc195d41882175d412fe40a8bc5730c5c
|
|
||||||
ARG HOWARD_ABRAMS_HAMACS_PATH=/foreign_documents/howardabrams/hamacs
|
|
||||||
ARG HOWARD_ABRAMS_HAMACS_REPO=https://github.com/howardabrams/hamacs.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_HAMACS_PATH && git -C $HOWARD_ABRAMS_HAMACS_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_HAMACS_PATH remote add origin $HOWARD_ABRAMS_HAMACS_REPO && git -C $HOWARD_ABRAMS_HAMACS_PATH fetch origin $HOWARD_ABRAMS_HAMACS_VERSION && git -C $HOWARD_ABRAMS_HAMACS_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_DEMO_IT_VERSION=e399fd7ceb73caeae7cb50b247359bafcaee2a3f
|
|
||||||
ARG HOWARD_ABRAMS_DEMO_IT_PATH=/foreign_documents/howardabrams/demo-it
|
|
||||||
ARG HOWARD_ABRAMS_DEMO_IT_REPO=https://github.com/howardabrams/demo-it.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_DEMO_IT_PATH && git -C $HOWARD_ABRAMS_DEMO_IT_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_DEMO_IT_PATH remote add origin $HOWARD_ABRAMS_DEMO_IT_REPO && git -C $HOWARD_ABRAMS_DEMO_IT_PATH fetch origin $HOWARD_ABRAMS_DEMO_IT_VERSION && git -C $HOWARD_ABRAMS_DEMO_IT_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_MAGIT_DEMO_VERSION=59e82f6bc7c18f550478d86a8f680c3f2da66985
|
|
||||||
ARG HOWARD_ABRAMS_MAGIT_DEMO_PATH=/foreign_documents/howardabrams/magit-demo
|
|
||||||
ARG HOWARD_ABRAMS_MAGIT_DEMO_REPO=https://github.com/howardabrams/magit-demo.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_MAGIT_DEMO_PATH && git -C $HOWARD_ABRAMS_MAGIT_DEMO_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_MAGIT_DEMO_PATH remote add origin $HOWARD_ABRAMS_MAGIT_DEMO_REPO && git -C $HOWARD_ABRAMS_MAGIT_DEMO_PATH fetch origin $HOWARD_ABRAMS_MAGIT_DEMO_VERSION && git -C $HOWARD_ABRAMS_MAGIT_DEMO_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_PDX_EMACS_HACKERS_VERSION=bfb7bd640fdf0ce3def21f9fc591ed35d776b26d
|
|
||||||
ARG HOWARD_ABRAMS_PDX_EMACS_HACKERS_PATH=/foreign_documents/howardabrams/pdx-emacs-hackers
|
|
||||||
ARG HOWARD_ABRAMS_PDX_EMACS_HACKERS_REPO=https://github.com/howardabrams/pdx-emacs-hackers.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_PDX_EMACS_HACKERS_PATH && git -C $HOWARD_ABRAMS_PDX_EMACS_HACKERS_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_PDX_EMACS_HACKERS_PATH remote add origin $HOWARD_ABRAMS_PDX_EMACS_HACKERS_REPO && git -C $HOWARD_ABRAMS_PDX_EMACS_HACKERS_PATH fetch origin $HOWARD_ABRAMS_PDX_EMACS_HACKERS_VERSION && git -C $HOWARD_ABRAMS_PDX_EMACS_HACKERS_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_FLORA_SIMULATOR_VERSION=50de13068722b9e3878f8598b749b7ccd14e7f8e
|
|
||||||
ARG HOWARD_ABRAMS_FLORA_SIMULATOR_PATH=/foreign_documents/howardabrams/flora-simulator
|
|
||||||
ARG HOWARD_ABRAMS_FLORA_SIMULATOR_REPO=https://github.com/howardabrams/flora-simulator.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_FLORA_SIMULATOR_PATH && git -C $HOWARD_ABRAMS_FLORA_SIMULATOR_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_FLORA_SIMULATOR_PATH remote add origin $HOWARD_ABRAMS_FLORA_SIMULATOR_REPO && git -C $HOWARD_ABRAMS_FLORA_SIMULATOR_PATH fetch origin $HOWARD_ABRAMS_FLORA_SIMULATOR_VERSION && git -C $HOWARD_ABRAMS_FLORA_SIMULATOR_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_VERSION=2d7a5e41001a1adf7ec24aeb6acc8525a72d7892
|
|
||||||
ARG HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_PATH=/foreign_documents/howardabrams/literate-devops-demo
|
|
||||||
ARG HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_REPO=https://github.com/howardabrams/literate-devops-demo.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_PATH && git -C $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_PATH remote add origin $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_REPO && git -C $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_PATH fetch origin $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_VERSION && git -C $HOWARD_ABRAMS_LITERATE_DEVOPS_DEMO_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_CLOJURE_YESQL_XP_VERSION=b651c7f8b47b2710e99fce9652980902bbc1c6c9
|
|
||||||
ARG HOWARD_ABRAMS_CLOJURE_YESQL_XP_PATH=/foreign_documents/howardabrams/clojure-yesql-xp
|
|
||||||
ARG HOWARD_ABRAMS_CLOJURE_YESQL_XP_REPO=https://github.com/howardabrams/clojure-yesql-xp.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_CLOJURE_YESQL_XP_PATH && git -C $HOWARD_ABRAMS_CLOJURE_YESQL_XP_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_CLOJURE_YESQL_XP_PATH remote add origin $HOWARD_ABRAMS_CLOJURE_YESQL_XP_REPO && git -C $HOWARD_ABRAMS_CLOJURE_YESQL_XP_PATH fetch origin $HOWARD_ABRAMS_CLOJURE_YESQL_XP_VERSION && git -C $HOWARD_ABRAMS_CLOJURE_YESQL_XP_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG HOWARD_ABRAMS_VEEP_VERSION=e37fcf63a5c4a526255735ee34955528b3b280ae
|
|
||||||
ARG HOWARD_ABRAMS_VEEP_PATH=/foreign_documents/howardabrams/veep
|
|
||||||
ARG HOWARD_ABRAMS_VEEP_REPO=https://github.com/howardabrams/veep.git
|
|
||||||
RUN mkdir -p $HOWARD_ABRAMS_VEEP_PATH && git -C $HOWARD_ABRAMS_VEEP_PATH init --initial-branch=main && git -C $HOWARD_ABRAMS_VEEP_PATH remote add origin $HOWARD_ABRAMS_VEEP_REPO && git -C $HOWARD_ABRAMS_VEEP_PATH fetch origin $HOWARD_ABRAMS_VEEP_VERSION && git -C $HOWARD_ABRAMS_VEEP_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG DOOMEMACS_VERSION=42d5fd83504f8aa80f3248036006fbcd49222943
|
|
||||||
ARG DOOMEMACS_PATH=/foreign_documents/doomemacs
|
|
||||||
ARG DOOMEMACS_REPO=https://github.com/doomemacs/doomemacs.git
|
|
||||||
RUN mkdir -p $DOOMEMACS_PATH && git -C $DOOMEMACS_PATH init --initial-branch=main && git -C $DOOMEMACS_PATH remote add origin $DOOMEMACS_REPO && git -C $DOOMEMACS_PATH fetch origin $DOOMEMACS_VERSION && git -C $DOOMEMACS_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG WORG_VERSION=ba6cda890f200d428a5d68e819eef15b5306055f
|
|
||||||
ARG WORG_PATH=/foreign_documents/worg
|
|
||||||
ARG WORG_REPO=https://git.sr.ht/~bzg/worg
|
|
||||||
RUN mkdir -p $WORG_PATH && git -C $WORG_PATH init --initial-branch=main && git -C $WORG_PATH remote add origin $WORG_REPO && git -C $WORG_PATH fetch origin $WORG_VERSION && git -C $WORG_PATH checkout FETCH_HEAD
|
|
||||||
|
|
||||||
ARG LITERATE_BUILD_EMACS_VERSION=e3ac1afe1e40af601be7af12c1d13d96308ab209
|
|
||||||
ARG LITERATE_BUILD_EMACS_PATH=/foreign_documents/literate_build_emacs
|
|
||||||
ARG LITERATE_BUILD_EMACS_REPO=https://gitlab.com/spudlyo/orgdemo2.git
|
|
||||||
RUN mkdir -p $LITERATE_BUILD_EMACS_PATH && git -C $LITERATE_BUILD_EMACS_PATH init --initial-branch=main && git -C $LITERATE_BUILD_EMACS_PATH remote add origin $LITERATE_BUILD_EMACS_REPO && git -C $LITERATE_BUILD_EMACS_PATH fetch origin $LITERATE_BUILD_EMACS_VERSION && git -C $LITERATE_BUILD_EMACS_PATH checkout FETCH_HEAD
|
|
||||||
# unused/aws.org contains invalid paths for setupfile which causes both upstream org-mode and Organic to error out.
|
|
||||||
RUN rm $LITERATE_BUILD_EMACS_PATH/unused/aws.org
|
|
||||||
|
|
||||||
FROM tester as foreign-document-test
|
|
||||||
RUN apk add --no-cache bash coreutils
|
|
||||||
RUN mkdir /foreign_documents
|
|
||||||
COPY --from=foreign-document-gather /foreign_documents/howardabrams /foreign_documents/howardabrams
|
|
||||||
COPY --from=foreign-document-gather /foreign_documents/doomemacs /foreign_documents/doomemacs
|
|
||||||
COPY --from=foreign-document-gather /foreign_documents/worg /foreign_documents/worg
|
|
||||||
COPY --from=foreign-document-gather /foreign_documents/literate_build_emacs /foreign_documents/literate_build_emacs
|
|
||||||
COPY --from=build-org-mode /root/org-mode /foreign_documents/org-mode
|
|
||||||
COPY --from=build-emacs /root/emacs /foreign_documents/emacs
|
|
||||||
ENTRYPOINT ["cargo", "run", "--bin", "foreign_document_test", "--features", "compare,foreign_document_test", "--profile", "release-lto"]
|
|
||||||
|
|||||||
@@ -6,11 +6,7 @@ all: build push
|
|||||||
|
|
||||||
.PHONY: build
|
.PHONY: build
|
||||||
build:
|
build:
|
||||||
docker build -t $(IMAGE_NAME) -f Dockerfile --target tester .
|
docker build -t $(IMAGE_NAME) -f Dockerfile ../../
|
||||||
|
|
||||||
.PHONY: build_foreign_document_test
|
|
||||||
build_foreign_document_test:
|
|
||||||
docker build -t $(IMAGE_NAME)-foreign-document -f Dockerfile --target foreign-document-test .
|
|
||||||
|
|
||||||
.PHONY: push
|
.PHONY: push
|
||||||
push:
|
push:
|
||||||
@@ -29,16 +25,11 @@ ifdef REMOTE_REPO
|
|||||||
else
|
else
|
||||||
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
@echo "REMOTE_REPO not defined, not removing from remote repo."
|
||||||
endif
|
endif
|
||||||
docker volume rm rust-cache cargo-cache
|
|
||||||
|
|
||||||
.PHONY: run
|
.PHONY: run
|
||||||
run: build
|
run:
|
||||||
docker run --rm --init --read-only --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source:ro" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target $(IMAGE_NAME) --no-default-features --features compare --no-fail-fast --lib --test test_loader
|
docker run --rm -i -t $(IMAGE_NAME)
|
||||||
|
|
||||||
.PHONY: shell
|
.PHONY: shell
|
||||||
shell: build
|
shell:
|
||||||
docker run --rm -i -t --entrypoint /bin/sh --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source:ro" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target $(IMAGE_NAME)
|
docker run --rm -i -t --entrypoint /bin/bash $(IMAGE_NAME)
|
||||||
|
|
||||||
.PHONY: run_foreign_document_test
|
|
||||||
run_foreign_document_test: build_foreign_document_test
|
|
||||||
docker run --rm --init --read-only --mount type=tmpfs,destination=/tmp -v "$$(readlink -f ../../):/source:ro" --workdir=/source --mount source=cargo-cache,target=/usr/local/cargo/registry --mount source=rust-cache,target=/target --env CARGO_TARGET_DIR=/target $(IMAGE_NAME)-foreign-document
|
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
This folder is for snippets of elisp that are useful for development.
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
(dolist (var org-element-affiliated-keywords)
|
|
||||||
(message "\"%s\"," (downcase var))
|
|
||||||
)
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
(dolist (var (sort (seq-filter 'listp org-entities)
|
|
||||||
(lambda (x y) (> (length (nth 0 x)) (length (nth 0 y))))))
|
|
||||||
(message "EntityDefinition {name: %s, latex_math_mode: %s, latex: %s, html: %s, ascii: %s, utf8: %s},"
|
|
||||||
(prin1-to-string (nth 0 var))
|
|
||||||
(if (nth 2 var) "true" "false")
|
|
||||||
(prin1-to-string (nth 1 var))
|
|
||||||
(prin1-to-string (nth 3 var))
|
|
||||||
(prin1-to-string (nth 4 var))
|
|
||||||
(prin1-to-string (nth 6 var))
|
|
||||||
)
|
|
||||||
)
|
|
||||||
@@ -1,42 +0,0 @@
|
|||||||
* Elisp Structure
|
|
||||||
| Keyword | Single | Double | Single Optval | Double Optval |
|
|
||||||
|---------+---------------+---------------+---------------+---------------|
|
|
||||||
| CAPTION | objtree | objtree | objtree | objtree |
|
|
||||||
| DATA | quoted(:name) | quoted(:name) | - | - |
|
|
||||||
| HEADER | list(quoted) | list(quoted) | - | - |
|
|
||||||
| NAME | quoted(:name) | quoted(:name) | - | - |
|
|
||||||
| PLOT | quoted(:plot) | quoted(:plot) | - | - |
|
|
||||||
| RESULTS | optional pair | optional pair | optional pair | optional pair |
|
|
||||||
* types
|
|
||||||
** objtree
|
|
||||||
Outer list: 1 per keyword
|
|
||||||
next list: first entry = list of objects for value. remaining entries = optval
|
|
||||||
** list(quoted)
|
|
||||||
List of quoted strings, 1 per keyword
|
|
||||||
** quoted(NAME)
|
|
||||||
Quoted string under the NAME property (for example quoted(:name))
|
|
||||||
** optional pair
|
|
||||||
When optval is supplied this is an alist with the field value being the real value and the 3nd value being the optval.
|
|
||||||
#+begin_src elisp
|
|
||||||
("*f*" . "*bar*")
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
When optval is not supplied this is a list containing a single string of the last occurrence of this keyword.
|
|
||||||
#+begin_src elisp
|
|
||||||
("*c*")
|
|
||||||
#+end_src
|
|
||||||
* Default settings
|
|
||||||
#+begin_src text
|
|
||||||
org-element-dual-keywords ("CAPTION" "RESULTS")
|
|
||||||
org-element-parsed-keywords ("CAPTION")
|
|
||||||
org-element-multiple-keywords ("CAPTION" "HEADER")
|
|
||||||
org-babel-results-keyword "RESULTS"
|
|
||||||
#+end_src
|
|
||||||
* Analysis
|
|
||||||
We don't have an example of a parsed non-dual keyword
|
|
||||||
|
|
||||||
Looks like multiple triggers list 1 per keyword
|
|
||||||
|
|
||||||
dual triggers support for optval
|
|
||||||
|
|
||||||
parsed triggers objects
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
#
|
|
||||||
set -euo pipefail
|
|
||||||
IFS=$'\n\t'
|
|
||||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
|
||||||
|
|
||||||
file_path="${DIR}/test_document.org"
|
|
||||||
|
|
||||||
for TARGET_VARIABLE in RESULTS CAPTION HEADER DATA NAME PLOT; do
|
|
||||||
INIT_SCRIPT=$(cat <<EOF
|
|
||||||
(progn
|
|
||||||
(erase-buffer)
|
|
||||||
(require 'org)
|
|
||||||
(defun org-table-align () t)
|
|
||||||
(setq vc-handled-backends nil)
|
|
||||||
(find-file "/input/${file_path}")
|
|
||||||
(org-mode)
|
|
||||||
(replace-regexp-in-region "foo" "${TARGET_VARIABLE}")
|
|
||||||
(message "%s" (pp-to-string (org-element-parse-buffer)))
|
|
||||||
)
|
|
||||||
EOF
|
|
||||||
)
|
|
||||||
docker run --init --rm -i --mount type=tmpfs,destination=/tmp -v "/:/input:ro" -w /input --entrypoint "" organic-test emacs -q --no-site-file --no-splash --batch --eval "$INIT_SCRIPT" 2> "${DIR}/${TARGET_VARIABLE}"
|
|
||||||
done
|
|
||||||
|
|
||||||
# exec docker run --init --rm -i -t --mount type=tmpfs,destination=/tmp -v "/:/input:ro" -w /input --entrypoint "" organic-test emacs -q --no-site-file --no-splash --eval "$INIT_SCRIPT"
|
|
||||||
|
|
||||||
# org-element-dual-keywords ("CAPTION" "RESULTS")
|
|
||||||
# org-element-parsed-keywords ("CAPTION")
|
|
||||||
# org-element-multiple-keywords ("CAPTION" "HEADER")
|
|
||||||
# org-babel-results-keyword "RESULTS"
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
# Single instance
|
|
||||||
#+foo: *a*
|
|
||||||
#+begin_example
|
|
||||||
|
|
||||||
#+end_example
|
|
||||||
|
|
||||||
# Two instances
|
|
||||||
#+foo: *b*
|
|
||||||
#+foo: *c*
|
|
||||||
#+begin_example
|
|
||||||
|
|
||||||
#+end_example
|
|
||||||
|
|
||||||
# Single with optval
|
|
||||||
#+foo[*bar*]: *d*
|
|
||||||
#+begin_example
|
|
||||||
|
|
||||||
#+end_example
|
|
||||||
|
|
||||||
# Two with optval
|
|
||||||
#+foo[*bar*]: *e*
|
|
||||||
#+foo[*bar*]: *f*
|
|
||||||
#+begin_example
|
|
||||||
|
|
||||||
#+end_example
|
|
||||||
@@ -25,4 +25,3 @@ This could significantly reduce our calls to exit matchers.
|
|||||||
I think targets would break this.
|
I think targets would break this.
|
||||||
|
|
||||||
The exit matchers are already implicitly building this behavior since they should all exit very early when the starting character is wrong. Putting this logic in a centralized place, far away from where those characters are actually going to be used, is unfortunate for readability.
|
The exit matchers are already implicitly building this behavior since they should all exit very early when the starting character is wrong. Putting this logic in a centralized place, far away from where those characters are actually going to be used, is unfortunate for readability.
|
||||||
** Use exit matcher to cut off trailing whitespace instead of re-matching in plain lists.
|
|
||||||
|
|||||||
@@ -1,7 +0,0 @@
|
|||||||
* Autogen tests
|
|
||||||
The autogen tests are the tests automatically generated to compare the output of Organic vs the upstream Emacs Org-mode parser using the sample documents in the =org_mode_samples= folder. They will have a prefix based on the settings for each test.
|
|
||||||
|
|
||||||
- default :: The test is run with the default settings (The upstream Emacs Org-mode determines the default settings)
|
|
||||||
- la :: Short for "list alphabetic". Enables alphabetic plain lists.
|
|
||||||
- t# :: Sets the tab-width to # (as in t4 sets the tab-width to 4).
|
|
||||||
- odd :: Sets the org-odd-levels-only setting to true (meaning "odd" as opposed to "oddeven").
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
This folder contains org-mode documents that get automatically included as tests using build.rs.
|
|
||||||
@@ -1,17 +0,0 @@
|
|||||||
#+name: foo
|
|
||||||
: bar
|
|
||||||
|
|
||||||
#+source: foo
|
|
||||||
: bar
|
|
||||||
|
|
||||||
#+tblname: foo
|
|
||||||
: bar
|
|
||||||
|
|
||||||
#+resname: foo
|
|
||||||
: bar
|
|
||||||
|
|
||||||
#+srcname: foo
|
|
||||||
: bar
|
|
||||||
|
|
||||||
#+label: foo
|
|
||||||
: bar
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
#+NAME: foo
|
|
||||||
bar
|
|
||||||
|
|
||||||
#+NaMe: baz
|
|
||||||
cat
|
|
||||||
|
|
||||||
#+name: lorem
|
|
||||||
ipsum
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
#+caption:
|
|
||||||
#+caption: *foo*
|
|
||||||
#+caption[bar]:
|
|
||||||
#+begin_src bash
|
|
||||||
#+end_src
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
#+name: foo
|
|
||||||
#+source: bar
|
|
||||||
#+name: baz
|
|
||||||
#+tblname: lorem
|
|
||||||
#+label: ipsum
|
|
||||||
: dolar
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
#+CAPTION[foo]: *bar*
|
|
||||||
#+CAPTION[*lorem* ipsum]: dolar
|
|
||||||
1. baz
|
|
||||||
|
|
||||||
|
|
||||||
#+CAPTION[foo]: *bar*
|
|
||||||
#+CAPTION[*lorem* ipsum]: dolar
|
|
||||||
# Comments cannot have affiliated keywords so those become regular keywords.
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
#+tblname: foo
|
|
||||||
: bar
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
foo
|
|
||||||
:end:
|
|
||||||
bar
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
foo
|
|
||||||
:end:
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
#+CATEGORY: theory
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
#+CATEGORY: foo
|
|
||||||
#+CATEGORY: bar
|
|
||||||
#+begin_src text
|
|
||||||
#+CATEGORY: baz
|
|
||||||
#+end_src
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
* foo
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
1. plain-list
|
1. foo
|
||||||
#+begin_center
|
#+begin_center
|
||||||
|
|
||||||
|
|
||||||
#+end_center
|
#+end_center
|
||||||
|
2. bar
|
||||||
Is this still in the plain list?
|
|
||||||
|
|||||||
1
org_mode_samples/exit_matcher_investigation/README.txt
Normal file
1
org_mode_samples/exit_matcher_investigation/README.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
This folder is an investigation into whether or not my exit matchers should operate from the top down or bottom up.
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
foo *bar baz * lorem* ipsum
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
Looks like 2 blank lines always exits the top-level plain list.
|
||||||
|
|
||||||
|
Plain lists do not seem to go inside paragraphs but rather exist beside them.
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
1. foo
|
||||||
|
|
||||||
|
bar
|
||||||
|
|
||||||
|
1. baz
|
||||||
|
|
||||||
|
lorem
|
||||||
|
|
||||||
|
ipsum
|
||||||
|
|
||||||
|
|
||||||
|
dolar
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Looks like table cells cannot contain lists but can contain bolds
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
ip *su* m
|
||||||
|
|
||||||
|
| foo | bar |
|
||||||
|
|----------+-----|
|
||||||
|
| 1. lo *re* m | |
|
||||||
@@ -1,74 +0,0 @@
|
|||||||
* Headline
|
|
||||||
before
|
|
||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
:candle:
|
|
||||||
inside
|
|
||||||
|
|
||||||
the drawer
|
|
||||||
:end:
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
:candle:
|
|
||||||
inside
|
|
||||||
|
|
||||||
the drawer
|
|
||||||
:end:
|
|
||||||
|
|
||||||
after
|
|
||||||
@@ -1,72 +0,0 @@
|
|||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
#+BEGIN: clocktable :scope file :maxlevel 2
|
|
||||||
#+CAPTION: Clock summary at [2023-08-25 Fri 05:34]
|
|
||||||
| Headline | Time |
|
|
||||||
|--------------+--------|
|
|
||||||
| *Total time* | *0:00* |
|
|
||||||
#+END:
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
#+BEGIN: clocktable :scope file :maxlevel 2
|
|
||||||
#+CAPTION: Clock summary at [2023-08-25 Fri 05:34]
|
|
||||||
| Headline | Time |
|
|
||||||
|--------------+--------|
|
|
||||||
| *Total time* | *0:00* |
|
|
||||||
#+END:
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
#+BEGIN: timestamp :format "%Y-%m-%d %H:%M"
|
|
||||||
|
|
||||||
#+END
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
#+BEGIN: clocktable :scope file :maxlevel 2
|
|
||||||
#+CAPTION: Clock summary at [2023-08-25 Fri 05:34]
|
|
||||||
| Headline | Time |
|
|
||||||
|--------------+--------|
|
|
||||||
| *Total time* | *0:00* |
|
|
||||||
#+END:
|
|
||||||
|
|
||||||
#+BEGIN: columnview :hlines 1 :id global
|
|
||||||
| ITEM | TODO | PRIORITY | TAGS |
|
|
||||||
|-------+------+----------+------------------------------|
|
|
||||||
| Foo | | B | |
|
|
||||||
|-------+------+----------+------------------------------|
|
|
||||||
| Bar | TODO | B | |
|
|
||||||
|-------+------+----------+------------------------------|
|
|
||||||
| Baz | | B | :thisisatag: |
|
|
||||||
| Lorem | | B | :thisshouldinheritfromabove: |
|
|
||||||
| Ipsum | | B | :multiple:tags: |
|
|
||||||
#+END:
|
|
||||||
* Foo
|
|
||||||
* TODO Bar
|
|
||||||
* Baz :thisisatag:
|
|
||||||
** Lorem :thisshouldinheritfromabove:
|
|
||||||
*** Ipsum :multiple:tags:
|
|
||||||
* Dolar ::
|
|
||||||
* cat :dog: bat
|
|
||||||
@@ -1,63 +0,0 @@
|
|||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
[fn:1] A footnote.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
[fn:1] A footnote.
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
* Footnotes
|
|
||||||
|
|
||||||
[fn:1]
|
|
||||||
|
|
||||||
#+BEGIN_EXAMPLE
|
|
||||||
baz
|
|
||||||
#+END_EXAMPLE
|
|
||||||
|
|
||||||
@@ -1,67 +0,0 @@
|
|||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
#+begin_center
|
|
||||||
|
|
||||||
#+end_center
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
#+begin_center
|
|
||||||
|
|
||||||
#+end_center
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
#+begin_center
|
|
||||||
|
|
||||||
#+end_center
|
|
||||||
|
|
||||||
#+begin_center
|
|
||||||
#+NAME: foo
|
|
||||||
|
|
||||||
#+end_center
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
#+begin_defun
|
|
||||||
foo
|
|
||||||
#+begin_lorem
|
|
||||||
,#+begin_center
|
|
||||||
bar
|
|
||||||
,#+end_center
|
|
||||||
ipsum
|
|
||||||
#+end_lorem
|
|
||||||
baz
|
|
||||||
#+end_defun
|
|
||||||
|
|
||||||
#+begin_center
|
|
||||||
#+begin_quote
|
|
||||||
#+begin_center
|
|
||||||
lorem
|
|
||||||
#+end_center
|
|
||||||
#+end_quote
|
|
||||||
#+end_center
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
#+begin_defun
|
|
||||||
foo
|
|
||||||
#+begin_lorem
|
|
||||||
ipsum
|
|
||||||
#+end_lorem
|
|
||||||
bar
|
|
||||||
#+begin_center
|
|
||||||
#+begin_quote
|
|
||||||
baz
|
|
||||||
#+end_quote
|
|
||||||
#+end_center
|
|
||||||
#+end_defun
|
|
||||||
@@ -1,67 +0,0 @@
|
|||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
#+begin_quote
|
|
||||||
|
|
||||||
#+end_quote
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
#+begin_quote
|
|
||||||
|
|
||||||
#+end_quote
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
#+begin_quote
|
|
||||||
|
|
||||||
foo
|
|
||||||
|
|
||||||
#+end_quote
|
|
||||||
@@ -1,71 +0,0 @@
|
|||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
#+begin_defun
|
|
||||||
foo
|
|
||||||
|
|
||||||
{{{bar(baz)}}}
|
|
||||||
#+end_defun
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
#+begin_defun
|
|
||||||
foo
|
|
||||||
|
|
||||||
{{{bar(baz)}}}
|
|
||||||
#+end_defun
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
#+begin_defun
|
|
||||||
foo
|
|
||||||
|
|
||||||
{{{bar(baz)}}}
|
|
||||||
#+end_defun
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
#+begin_defun foo bar baz
|
|
||||||
lorem
|
|
||||||
#+end_defun
|
|
||||||
@@ -1,63 +0,0 @@
|
|||||||
#+NAME: a
|
|
||||||
#+caption: b *lorem* ipsum
|
|
||||||
#+results: c
|
|
||||||
#+headers: d
|
|
||||||
#+header: e
|
|
||||||
#+label: f
|
|
||||||
#+plot: g
|
|
||||||
#+resname: h
|
|
||||||
#+result: i
|
|
||||||
#+source: j
|
|
||||||
#+srcname: k
|
|
||||||
#+tblname: l
|
|
||||||
#+attr_latex: m
|
|
||||||
#+attr_html: n
|
|
||||||
#+NAME: aa
|
|
||||||
#+caption: bb *lorem* ipsum
|
|
||||||
#+results: cc
|
|
||||||
#+headers: dd
|
|
||||||
#+header: ee
|
|
||||||
#+label: ff
|
|
||||||
#+plot: gg
|
|
||||||
#+resname: hh
|
|
||||||
#+result: ii
|
|
||||||
#+source: jj
|
|
||||||
#+srcname: kk
|
|
||||||
#+tblname: ll
|
|
||||||
#+attr_latex: mm
|
|
||||||
#+attr_html: nn
|
|
||||||
1. bar
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#+NAME: A
|
|
||||||
#+CAPTION: B *LOREM* IPSUM
|
|
||||||
#+RESULTS: C
|
|
||||||
#+HEADERS: D
|
|
||||||
#+HEADER: E
|
|
||||||
#+LABEL: F
|
|
||||||
#+PLOT: G
|
|
||||||
#+RESNAME: H
|
|
||||||
#+RESULT: I
|
|
||||||
#+SOURCE: J
|
|
||||||
#+SRCNAME: K
|
|
||||||
#+TBLNAME: L
|
|
||||||
#+ATTR_LATEX: M
|
|
||||||
#+ATTR_HTML: N
|
|
||||||
#+NAME: AA
|
|
||||||
#+CAPTION: BB *LOREM* IPSUM
|
|
||||||
#+RESULTS: CC
|
|
||||||
#+HEADERS: DD
|
|
||||||
#+HEADER: EE
|
|
||||||
#+LABEL: FF
|
|
||||||
#+PLOT: GG
|
|
||||||
#+RESNAME: HH
|
|
||||||
#+RESULT: II
|
|
||||||
#+SOURCE: JJ
|
|
||||||
#+SRCNAME: KK
|
|
||||||
#+TBLNAME: LL
|
|
||||||
#+ATTR_LATEX: MM
|
|
||||||
#+ATTR_HTML: NN
|
|
||||||
1. BAR
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
# An ordered list starting at 3
|
|
||||||
1. [@3] foo
|
|
||||||
|
|
||||||
|
|
||||||
# An ordered list starting at 11
|
|
||||||
1. [@D] bar
|
|
||||||
|
|
||||||
|
|
||||||
# An ordered list starting at 1 with the contents of "[@kk] baz"
|
|
||||||
1. [@kk] baz
|
|
||||||
|
|
||||||
|
|
||||||
# A paragraph when org-list-allow-alphabetical is nil
|
|
||||||
m. lorem
|
|
||||||
|
|
||||||
|
|
||||||
# A paragraph when org-list-allow-alphabetical is nil
|
|
||||||
m. [@k] ipsum
|
|
||||||
|
|
||||||
|
|
||||||
# An unordered list with :counter set to 3
|
|
||||||
- [@3] dolar
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
# Alphabetic lists larger than 26 elements should become numbered. From M-x describe-variable org-list-allow-alphabetical:
|
|
||||||
#
|
|
||||||
# > Lists with more than 26 items will fallback to standard numbering.
|
|
||||||
a. 1
|
|
||||||
a. 2
|
|
||||||
a. 3
|
|
||||||
a. 4
|
|
||||||
a. 5
|
|
||||||
a. 6
|
|
||||||
a. 7
|
|
||||||
a. 8
|
|
||||||
a. 9
|
|
||||||
a. 10
|
|
||||||
a. 11
|
|
||||||
a. 12
|
|
||||||
a. 13
|
|
||||||
a. 14
|
|
||||||
a. 15
|
|
||||||
a. 16
|
|
||||||
a. 17
|
|
||||||
a. 18
|
|
||||||
a. 19
|
|
||||||
a. 20
|
|
||||||
a. 21
|
|
||||||
a. 22
|
|
||||||
a. 23
|
|
||||||
a. 24
|
|
||||||
a. 25
|
|
||||||
a. 26
|
|
||||||
a. 27
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
# These are only allowed by configuring org-list-allow-alphabetical which the automated tests are not currently set up to do, so this will parse as a paragraph:
|
|
||||||
a. foo
|
|
||||||
b. bar
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
- [ ] Foo
|
|
||||||
- [-] Bar
|
|
||||||
- [X] Baz
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
1. foo
|
|
||||||
2.
|
|
||||||
bar
|
|
||||||
1.
|
|
||||||
#+begin_center
|
|
||||||
Still in the list
|
|
||||||
#+end_center
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
3. [@3] foo
|
|
||||||
4. bar
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
- foo ::
|
|
||||||
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
- foo :: bar
|
|
||||||
- cat ::
|
|
||||||
dog
|
|
||||||
- lorem
|
|
||||||
:: ipsum
|
|
||||||
-
|
|
||||||
lorem :: ipsum
|
|
||||||
- dolar *bold* foo :: ipsum
|
|
||||||
- big gap ::
|
|
||||||
|
|
||||||
stuff
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
- foo ::
|
|
||||||
|
|
||||||
- bar ::
|
|
||||||
|
|
||||||
|
|
||||||
baz
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
- {{{foo(bar)}}} :: baz
|
|
||||||
- =foo= :: bar
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
- foo :: bar
|
|
||||||
- foo :: bar
|
|
||||||
- foo :: bar
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
- =foo :: bar= :: baz
|
|
||||||
- lorem :: ipsum :: dolar
|
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
1.
|
1.
|
||||||
2.
|
2.
|
||||||
3.
|
3.
|
||||||
|
|
||||||
* headline
|
|
||||||
|
|||||||
@@ -1,3 +0,0 @@
|
|||||||
1. foo
|
|
||||||
#+NAME: bar
|
|
||||||
2. baz
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
1. foo
|
|
||||||
- bar
|
|
||||||
- lorem :: ipsum
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
# Since this is an ordered list, the text before the " :: " is NOT parsed as a tag.
|
|
||||||
1. foo :: bar
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
# This test causes problems with regular links if we do not create a new ContextTree when calling into confine_context.
|
|
||||||
- foo [[info:bar][baz]] lorem
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
# "lorem" is prefixed by a tab instead of spaces, so the editor's tab-width value determines whether lorem is a sibling of baz (tab-width 8), a sibling of bar (tab-width < 8), or a child of baz (tab-width > 8).
|
|
||||||
1. foo
|
|
||||||
1. bar
|
|
||||||
1. baz
|
|
||||||
1. lorem
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
- foo
|
|
||||||
|
|
||||||
@@ -1,32 +1,3 @@
|
|||||||
* Empty
|
|
||||||
:PROPERTIES:
|
|
||||||
:END:
|
|
||||||
* Single new line
|
|
||||||
:PROPERTIES:
|
:PROPERTIES:
|
||||||
|
|
||||||
:END:
|
|
||||||
* Single line with spaces
|
|
||||||
:PROPERTIES:
|
|
||||||
|
|
||||||
:END:
|
|
||||||
* Many lines, first line without spaces
|
|
||||||
:PROPERTIES:
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:END:
|
|
||||||
* Many lines, first line with spaces
|
|
||||||
:PROPERTIES:
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:END:
|
|
||||||
* Many lines, first line with spaces, later line with spaces
|
|
||||||
:PROPERTIES:
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:END:
|
:END:
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
* baz
|
|
||||||
# lorem
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
* baz
|
|
||||||
# lorem
|
|
||||||
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
* baz
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
** Foo
|
|
||||||
DEADLINE: <2023-10-16 Mon>
|
|
||||||
:PROPERTIES:
|
|
||||||
:foo: *a*
|
|
||||||
:Bar: *b*
|
|
||||||
:BAZ: *c*
|
|
||||||
:END:
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
* baz
|
|
||||||
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
* baz
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# lorem
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
:PROPERTIES:
|
|
||||||
:foo: bar
|
|
||||||
:foo+: baz
|
|
||||||
:cat: dog
|
|
||||||
:END:
|
|
||||||
|
|
||||||
# Even though these are inheriting the properties and overwriting and/or appending to them, this is not represented in the parser AST so Organic does not do any special handling of this.
|
|
||||||
|
|
||||||
* Overwrite
|
|
||||||
:PROPERTIES:
|
|
||||||
:foo: lorem
|
|
||||||
:bat: car
|
|
||||||
:END:
|
|
||||||
|
|
||||||
* Append
|
|
||||||
:PROPERTIES:
|
|
||||||
:foo+: ipsum
|
|
||||||
:cake: lie
|
|
||||||
:END:
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
* Overwrite
|
|
||||||
:PROPERTIES:
|
|
||||||
:header-args: :var foo="lorem"
|
|
||||||
:header-args:emacs-lisp: :var bar="ipsum"
|
|
||||||
:header-args:emacs-lisp+: :results silent :var baz=7
|
|
||||||
:END:
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
* Overwrite
|
|
||||||
#+NAME: foo
|
|
||||||
:PROPERTIES:
|
|
||||||
:header-args: :var foo="lorem"
|
|
||||||
:END:
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
** foo
|
|
||||||
:PROPERTIES:
|
|
||||||
:DESCRIPTION: lorem
|
|
||||||
:ALT_TITLE: ipsum
|
|
||||||
:END:
|
|
||||||
|
|
||||||
bar
|
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Blank lines and comments can come before property drawers in the zeroth section
|
||||||
|
:PROPERTIES:
|
||||||
|
:FOO: bar
|
||||||
|
:END:
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
* Spaces turn property drawers into regular drawers
|
||||||
|
|
||||||
|
:PROPERTIES:
|
||||||
|
:FOO: bar
|
||||||
|
:END:
|
||||||
|
* Comments turn property drawers into regular drawers
|
||||||
|
# Comment
|
||||||
|
:PROPERTIES:
|
||||||
|
:FOO: bar
|
||||||
|
:END:
|
||||||
|
* Baseline
|
||||||
|
:PROPERTIES:
|
||||||
|
:FOO: bar
|
||||||
|
:END:
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
# lorem
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
# lorem
|
|
||||||
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# lorem
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
:PROPERTIES:
|
|
||||||
:FOO: bar
|
|
||||||
:END:
|
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Blank lines and comments can come before property drawers in the zeroth section
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
:PROPERTIES:
|
||||||
|
:FOO: bar
|
||||||
|
:END:
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user