Skip to content

Commit 84545e9

Browse files
Initial commit
0 parents  commit 84545e9

File tree

6 files changed

+141
-0
lines changed

6 files changed

+141
-0
lines changed

.github/workflows/check.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: check
2+
on: [push, pull_request]
3+
jobs:
4+
reapack-index:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- name: Fetch repository
8+
uses: actions/checkout@v4
9+
- name: Install Pandoc
10+
run: sudo apt-get install -yy pandoc
11+
- name: Set up Ruby
12+
uses: ruby/setup-ruby@v1
13+
with:
14+
ruby-version: 3.2
15+
- name: Install reapack-index
16+
run: gem install reapack-index
17+
- name: Validate packages
18+
run: reapack-index --check

.github/workflows/deploy.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: deploy
2+
on:
3+
push:
4+
branches: [master]
5+
jobs:
6+
reapack-index:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Fetch repository
10+
uses: actions/checkout@v4
11+
with:
12+
fetch-depth: 0
13+
- name: Configure git
14+
run: |-
15+
git config user.name 'ReaTeam Bot'
16+
git config user.email 'reateam-bot@cfillion.ca'
17+
- name: Install Pandoc
18+
run: sudo apt-get install -yy pandoc
19+
- name: Set up Ruby
20+
uses: ruby/setup-ruby@v1
21+
with:
22+
ruby-version: 3.2
23+
- name: Install reapack-index
24+
run: gem install reapack-index
25+
- name: Update index.xml
26+
run: reapack-index --commit
27+
- name: Push changes
28+
run: git push

.reapack-index.conf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
--about README.md
2+
--commit-template "index: $changelog
3+
4+
[ci skip]"

Example/cfillion_Hello world.lua

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
-- @description Hello world
2+
-- @author cfillion
3+
-- @version 1.0
4+
-- @about
5+
-- This is an example of a package file. It installs itself as a ReaScript that
6+
-- does nothing but show "Hello World!" in REAPER's scripting console.
7+
--
8+
-- Packages may also include additional files specified using the @provides tag.
9+
--
10+
-- This text is the documentation shown when using ReaPack's "About this package"
11+
-- feature. [Markdown](https://commonmark.org/) *formatting* is supported.
12+
13+
reaper.ShowConsoleMsg 'Hello World!'

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# ReaPack Repository Template
2+
3+
A template for GitHub-hosted ReaPack repositories with automated
4+
[reapack-index](https://github.com/cfillion/reapack-index)
5+
running from GitHub Actions.
6+
7+
Replace the name of the repository in [index.xml](/index.xml) when using this template.
8+
This will be the name shown in ReaPack.
9+
10+
```xml
11+
<index version="1" name="Name of your repository here">
12+
```
13+
14+
Replace the contents of this file ([README.md](/README.md)).
15+
This will be the text shown when using ReaPack's "About this repository" feature.
16+
17+
reapack-index looks for package files in subfolders.
18+
The folder tree represents the package categories shown in ReaPack.
19+
20+
Each package file is expected to begin with a metadata header.
21+
See [Packaging Documentation](https://github.com/cfillion/reapack-index/wiki/Packaging-Documentation) on reapack-index's wiki.
22+
23+
The URL to import in ReaPack is [https://github.com/`<your username>`/`<repository name>`/raw/master/index.xml](https://github.com/cfillion/reapack-repository-template/raw/master/index.xml).

index.xml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<index version="1" name="ReaPack Repository Template" commit="58a3e39ba95bd0f35846aa1f39aa4cb2574295e1">
3+
<category name="Example">
4+
<reapack name="cfillion_Hello world.lua" type="script" desc="Hello world">
5+
<metadata>
6+
<description><![CDATA[{\rtf1\ansi\deff0{\fonttbl{\f0 \fswiss Helvetica;}{\f1 Courier;}}
7+
{\colortbl;\red255\green0\blue0;\red0\green0\blue255;}
8+
\widowctrl\hyphauto
9+
10+
{\pard \ql \f0 \sa180 \li0 \fi0 This is an example of a package file. It installs itself as a ReaScript that does nothing but show "Hello World!" in REAPER's scripting console.\par}
11+
{\pard \ql \f0 \sa180 \li0 \fi0 Packages may also include additional files specified using the @provides tag.\par}
12+
{\pard \ql \f0 \sa180 \li0 \fi0 This text is the documentation shown when using ReaPack's "About this package" feature. {\field{\*\fldinst{HYPERLINK "https://commonmark.org/"}}{\fldrslt{\ul
13+
Markdown
14+
}}}
15+
{\i formatting} is supported.\par}
16+
}
17+
]]></description>
18+
</metadata>
19+
<version name="1.0" author="cfillion" time="2021-01-04T23:30:32Z">
20+
<source main="main">https://github.com/cfillion/reapack-repository-template/raw/58a3e39ba95bd0f35846aa1f39aa4cb2574295e1/Example/cfillion_Hello%20world.lua</source>
21+
</version>
22+
</reapack>
23+
</category>
24+
<metadata>
25+
<description><![CDATA[{\rtf1\ansi\deff0{\fonttbl{\f0 \fswiss Helvetica;}{\f1 Courier;}}
26+
{\colortbl;\red255\green0\blue0;\red0\green0\blue255;}
27+
\widowctrl\hyphauto
28+
29+
{\pard \ql \f0 \sa180 \li0 \fi0 \b \fs36 ReaPack Repository Template\par}
30+
{\pard \ql \f0 \sa180 \li0 \fi0 A template for GitHub-hosted ReaPack repositories with automated {\field{\*\fldinst{HYPERLINK "https://github.com/cfillion/reapack-index"}}{\fldrslt{\ul
31+
reapack-index
32+
}}}
33+
running from GitHub Actions.\par}
34+
{\pard \ql \f0 \sa180 \li0 \fi0 Replace the name of the repository in {\field{\*\fldinst{HYPERLINK "/index.xml"}}{\fldrslt{\ul
35+
index.xml
36+
}}}
37+
when using this template. This will be the name shown in ReaPack.\par}
38+
{\pard \ql \f0 \sa180 \li0 \fi0 \f1 <index version="1" name="Name of your repository here">\par}
39+
{\pard \ql \f0 \sa180 \li0 \fi0 Replace the contents of this file ({\field{\*\fldinst{HYPERLINK "/README.md"}}{\fldrslt{\ul
40+
README.md
41+
}}}
42+
). This will be the text shown when using ReaPack's "About this repository" feature.\par}
43+
{\pard \ql \f0 \sa180 \li0 \fi0 reapack-index looks for package files in subfolders. The folder tree represents the package categories shown in ReaPack.\par}
44+
{\pard \ql \f0 \sa180 \li0 \fi0 Each package file is expected to begin with a metadata header. See {\field{\*\fldinst{HYPERLINK "https://github.com/cfillion/reapack-index/wiki/Packaging-Documentation"}}{\fldrslt{\ul
45+
Packaging Documentation
46+
}}}
47+
on reapack-index's wiki.\par}
48+
{\pard \ql \f0 \sa180 \li0 \fi0 The URL to import in ReaPack is {\field{\*\fldinst{HYPERLINK "https://github.com/cfillion/reapack-repository-template/raw/master/index.xml"}}{\fldrslt{\ul
49+
https://github.com/{\f1 <your username>}/{\f1 <repository name>}/raw/master/index.xml
50+
}}}
51+
.\par}
52+
}
53+
]]></description>
54+
</metadata>
55+
</index>

0 commit comments

Comments
 (0)