Skip to content

Commit 18ca3a7

Browse files
committed
2 parents edd600e + f52616f commit 18ca3a7

File tree

3 files changed

+87
-12
lines changed

3 files changed

+87
-12
lines changed
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: Generate French Railway Signalling Presets Archive
2+
3+
# Controls when the workflow will run
4+
on:
5+
# Triggers the workflow on push or pull request events but only for the "main" branch
6+
push:
7+
paths:
8+
- 'JOSM/Presets/**'
9+
branches: [ "main" ]
10+
pull_request:
11+
paths:
12+
- 'JOSM/Presets/**'
13+
branches: [ "main" ]
14+
# Allows you to run this workflow manually from the Actions tab
15+
workflow_dispatch:
16+
17+
# Add permissions for the GITHUB_TOKEN
18+
permissions:
19+
contents: write
20+
actions: read
21+
22+
jobs:
23+
# This workflow contains a single job called "generate-archive"
24+
generate-archive:
25+
runs-on: ubuntu-latest
26+
27+
steps:
28+
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
29+
- name: Checkout repository
30+
uses: actions/checkout@v4
31+
with:
32+
# Required to push changes
33+
token: ${{ secrets.GITHUB_TOKEN }}
34+
35+
# Create the presets archive
36+
- name: Create presets archive
37+
run: |
38+
cd JOSM/Presets
39+
zip -r ../../French_Railway_Signalling_presets.zip . -x "*.git*" "*.DS_Store*" "*.tmp*"
40+
cd ../..
41+
42+
# Check if the archive changed (handle first run)
43+
- name: Check if archive changed
44+
id: check_changes
45+
run: |
46+
if [ ! -f "French_Railway_Signalling_presets.zip" ]; then
47+
echo "Archive doesn't exist yet, will create it"
48+
echo "changed=true" >> $GITHUB_OUTPUT
49+
elif git diff --quiet French_Railway_Signalling_presets.zip 2>/dev/null; then
50+
echo "Archive unchanged"
51+
echo "changed=false" >> $GITHUB_OUTPUT
52+
else
53+
echo "Archive changed"
54+
echo "changed=true" >> $GITHUB_OUTPUT
55+
fi
56+
57+
# Commit and push the new archive if it changed
58+
- name: Commit and push updated archive
59+
if: steps.check_changes.outputs.changed == 'true'
60+
run: |
61+
git config --local user.email "action@github.com"
62+
git config --local user.name "GitHub Action"
63+
git add French_Railway_Signalling_presets.zip
64+
git commit -m "Auto-update French Railway Signalling presets archive [skip ci]"
65+
git push
98.5 KB
Binary file not shown.

README.md

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,33 @@
11
# French Railway Signalling
22

3-
A set of templates and Lua modules that help document French railway signalling on the [OpenRailwayMap wiki](https://wiki.openstreetmap.org/wiki/OpenRailwayMap/Tagging_in_France).
4-
5-
This repository serves as a backup of the pages authored on the OSM Wiki related to French railway tagging and signalling conventions. It ensures long-term preservation of the documentation and makes it easier to track changes over time.
3+
This repository serves as a **backup** of the pages, Lua modules, and templates I authored for the [OpenRailwayMap wiki](https://wiki.openstreetmap.org/wiki/OpenRailwayMap/Tagging_in_France), focusing on **French railway signalling**. It ensures long-term preservation of the documentation in case of unexpected deletions or inappropriate edits on the wiki platform.
64

75
## JOSM Presets
86

9-
This repository also contains JOSM presets specifically tailored to French railway infrastructure. These presets are designed to reflect the current revision of the wiki and are continuously updated to remain in sync with it.
7+
The repository also includes **JOSM presets** specifically designed for mapping French railway signalling. These presets are aligned with the current revision of the wiki documentation and are actively maintained to remain up to date.
8+
9+
### Installation
10+
11+
The recommended way to use the presets is to install them directly from within the [JOSM](https://josm.openstreetmap.de) application:
12+
13+
1. Go to **Presets****Presets Preferences****Tagging Presets**.
14+
2. Search for **French Railway Signalling** in the **Available Presets** search box.
15+
3. Select the matching preset.
16+
4. Click the right-pointing arrow to add it to **Active Presets**.
17+
5. Click OK.
18+
19+
Alternatively, you can download and install the presets manually:
1020

11-
⚠️ **Work in progress** — presets and documentation are actively maintained and subject to improvement.
21+
⬇️ [Download the ZIP archive](https://raw.githubusercontent.com/noeldev/FrenchRailwaySignalling/main/French_Railway_Signalling_presets.zip)
1222

13-
## Contents
23+
This archive contains the latest preset XML files along with the required icon assets (SVG and PNG).
1424

15-
- Backup of wiki pages
16-
- Custom JOSM preset file with contextual tagging options
17-
- Supporting Lua modules and templates for structured content
25+
## Notes
1826

19-
## Related links
27+
- All icons (SVG/PNG) are either original creations or adaptations of files from Wikimedia Commons, or from [Nicolas Wurtz’s signalisation-rfn-svg project](https://github.com/nicolaswurtz/signalisation-rfn-svg).
28+
- This project is a **work in progress**. Both the presets and the associated documentation are continuously improved.
2029

21-
- 🌐 [Main Wiki Page (English)](https://wiki.openstreetmap.org/wiki/OpenRailwayMap/Tagging_in_France)
22-
- 🗺️ [OpenRailwayMap](https://www.openrailwaymap.org)
30+
## Related Links
2331

32+
- 🌐 [Main Wiki Page – Tagging in France (EN)](https://wiki.openstreetmap.org/wiki/OpenRailwayMap/Tagging_in_France)
33+
- 🗺️ [OpenRailwayMap](https://www.openrailwaymap.app)

0 commit comments

Comments
 (0)