1
0
mirror of https://github.com/moparisthebest/xeps synced 2024-11-21 16:55:07 -05:00
Commit Graph

64 Commits

Author SHA1 Message Date
Guus der Kinderen
fbc0072c92 for #1235: fix incorrect exemption for XEP-0143 2022-11-06 20:31:58 +01:00
Guus der Kinderen
bee4c93cd3 for #1235: Do not exit script when XPATH yields no result
xmllint will return exit code 10 when an XPATH query finds no matches. With the changes in this commit, the script isn't stopped. Instead, it uses an empty value, which is likely to cause the validation checks (further down in the script) to fail.
2022-11-06 20:08:15 +01:00
Guus der Kinderen
028fd1a685 for #1235: Add legal notice validation
This adds a check for the usage of the _entity reference_ that is the legal notice.
2022-11-06 19:20:34 +01:00
Guus der Kinderen
56cef32c91 for #1235: Add header type validation. 2022-11-06 11:11:13 +01:00
Guus der Kinderen
da76032e24 for #1235: Add revision block version validation. 2022-11-06 10:40:02 +01:00
Guus der Kinderen
269e4d620a for #1235: Add xep.xsl XML stylesheet usage validation 2022-11-06 10:14:54 +01:00
Guus der Kinderen
3f6f199159 for #1235: variable casing to conform to convention 2022-11-06 09:45:33 +01:00
Guus der Kinderen
f1197f143a for #1235: Double quote to prevent globbing and word splitting.
As per @horazont's feedback:
> Whenever you reference a variable ($foobar) and unless you know what you're doing, put it in double quotes.
2022-11-06 09:40:32 +01:00
Guus der Kinderen
7389c8a3e9 for #1235: Remove redundant braces in if-expression
As per @horazont's feedback:
> You do not need () around the command in an if. I think that causes a subshell to spawn, the effects of which I'm not certain about.

Further Googling suggests that the exit status of a pipeline is that of the most recently executed foreground pipeline, meaning that the exit code can be used directly in conditional statements.
2022-11-06 09:33:59 +01:00
Guus der Kinderen
d65a5b4c2f for #1235: Use set -euo pipefail instead of set -e
As per @horazont's feedback: `-u` shouts at you if you use an undefined variable (very useful to catch typos)
and `-o pipefail` improves error handling by also failing if any of the commands in a pipe fail.
2022-11-06 09:29:18 +01:00
Guus der Kinderen
a7149be8c0 fixes #1235: Script that validates XEP-0001 conformance
This adds a simple bash script that checks if a provided file (filename to be provided as first argument) conforms to XEP-0001.

Expected to be executed from the directory that holds all xep XML files.
Requires one argument: the file name of the xep to be validated, eg:

    $ tools/validate-xep0001-conformance.sh xep-0010.xml

exit status will be non-zero upon validation failure.

requires: bash, xmllint
2022-11-05 16:53:26 +01:00
Jonas Schäfer
f200f3517b Handle s/Draft/Stable/ in send-updates.py 2021-10-12 20:49:36 +02:00
Kim Alvefur
318e25bd6c xep2md: fix spaces around links or spans
Don't remember why it did this here. There's another spot where it
removes longer stretches of whitespace. Doesn't trim leading or trailing
whitespace tho, but that's what breaks it here.
2021-04-03 14:19:54 +02:00
Kim Alvefur
e7e1fca3bf Pass trough entity references into markdown
In order to allow e.g. &xepnnnn; references in text.
2021-03-03 15:51:19 +01:00
Kim Alvefur
0ccc34d1cf Reduce error on missing required metadata to yelling on stderr 2021-03-03 15:51:19 +01:00
Kim Alvefur
e7625fa93b Allow dependencies to be missing from metadata
xep2md leaves it out if there are zero dependencies in the input, so
seems sensible to mirror that in the opposite direction
2021-03-03 15:51:19 +01:00
Kim Alvefur
297511b1cd xep2md: Warn if lua-yaml is missing
Since this does not carry the full metadata needed to roundtrip the
document, which can be fine if you're using the markdown for something
else.
2021-03-02 17:42:20 +01:00
Kim Alvefur
e6afb36d92 xep2md: Fix collection of date for simple metadata
Thanks jonas’

Another hook collected revision dates before this one
2021-03-02 17:42:07 +01:00
Kim Alvefur
d3d6c62426 xep2md: Include JID in author entry 2021-02-26 12:36:32 +01:00
Kim Alvefur
3dc3253a38 xep2md: Always serialize authors as list
Needed to roundtrip through 2xep.lua
2021-02-26 12:35:25 +01:00
Kim Alvefur
d562d815b5 Add tool to produce diff of markdown 2021-02-18 16:48:50 +01:00
Kim Alvefur
d4ea984d85 tools/xep2md.sh: Fix stuff reference to xep2md.lua
I had all these in the main source directory initially, hence the
relative paths, which broke after moving them into tools/
2021-02-18 16:47:31 +01:00
Kim Alvefur
e8d73dec14 Tweak headers of to/from markdown tooling 2021-02-17 16:28:31 +01:00
Kim Alvefur
10da72c298 Add tooling for conversion to/from Markdown
Long past time I recorded these somewhere.
2021-02-14 02:12:23 +01:00
Jonas Schäfer
033ad4007a tools: auto-generate entity into xep.ent upon acceptance 2020-11-24 18:56:46 +01:00
Jonas Schäfer
7941813d79 ci: correctly detect outdated branches 2020-06-14 15:46:56 +02:00
Jonas Schäfer
b028cca04d ci: use git merge-base to detect changed files
This prevents false positives if the branch is not rebased on
current main.
2020-06-14 15:46:56 +02:00
Jonas Schäfer
bf5bace92e ci: do not include deleted files in the changed builds 2020-06-14 15:46:52 +02:00
Jonas Schäfer
0dbfaff260 Create GitLab.com CI pipeline
This pipeline features the following:

- Building of an nginx image with the XEPs as static files,
  in all formats.
- Incremental builds on the main branch and incremental builds
  for MRs based on the last main build.
- Automatic archiving of changed XEPs to the attic
- Automatic announcement to the mailing lists
2020-06-14 14:09:35 +02:00
Jonas Schäfer
2ea54d4a3c send-updates.py: Introduce support to skip editorial changes
We generally do not want to announce those on the mailing lists,
so this switch allows us to avoid having to run without -y.
2020-06-14 11:09:47 +02:00
Jonas Schäfer
7eb2c2e095 archive.py: add support for skipping building during archiving
If it is known that the documents have already been built or if it
is imperative to use the versions built even if local changes have
been applied since the last build, this switch comes in handy.
2020-06-14 11:09:19 +02:00
Jonas Schäfer
02b9c22b1d Add flag to suppress insertion of revision block for deferrals 2020-01-02 17:59:27 +01:00
Sam Whited
04c9106434 tools: be more specific about XEP filenames
Sometimes the main working directory may have other XML files such as
the temporary files generated by TeXML (xep-*.tex.xml) which may be
picked up by the metadata script. Use a more specific pattern so that it
only extracts metadata from real XEP files.
2019-12-19 18:04:42 -05:00
Jonas Schäfer
0b1bea7835 tools: fix help of accept.py 2019-02-04 16:41:20 +01:00
Jonas Schäfer
cb8936de67 tools: Support for <ul/> in revision history 2019-01-13 12:20:01 +01:00
Jonas Wielicki
d8ed29765f Add CSV generator tool 2018-04-05 14:55:49 +02:00
Jonas Wielicki
2a5de8c7c4 Create tool to issue Call For Experience, similar to send-updates 2018-03-07 20:05:06 +01:00
Jonas Wielicki
8aeef7b526 Create tool to generate xep.ent entries 2018-03-06 13:56:57 +01:00
Jonas Wielicki
97f21995a2 tools: allow archive.py to override archived XEPs 2018-02-23 08:23:57 +01:00
Jonas Wielicki
1409f2722d Add commit capability to deferrals.py 2018-01-25 13:44:58 +01:00
Jonas Wielicki
1cac2f9918 Fix typo 2018-01-25 13:38:32 +01:00
Jonas Wielicki
6e1bdc781e Remove unused code from accept.py 2018-01-25 09:27:52 +01:00
Jonas Wielicki
0202f9166b Add option to commit right away to accept.py 2018-01-25 09:08:49 +01:00
Jonas Wielicki
8b2223b18e Make proper semver in {accept,deferrals}.py 2018-01-25 09:04:41 +01:00
Jonas Wielicki
a512dadefa Implement tool to accept ProtoXEPs 2018-01-25 08:46:43 +01:00
Jonas Wielicki
0d1235127d tools: Support for re-issuing a Last Call 2017-12-07 14:58:31 +01:00
Jonas Wielicki
88b0cfa8ef Fix missing .html in find-lcs.sh 2017-11-29 19:20:10 +01:00
Jonas Wielicki
aaee098d70 Add note about XEP index staleness 2017-11-29 19:20:10 +01:00
Jonas Wielicki
d97c1af508 Add a tool to find open last calls 2017-11-29 19:20:10 +01:00
Jonas Wielicki
373a95c214 Make archive.py build the XEPs 2017-11-29 12:45:43 +01:00