-
-
Notifications
You must be signed in to change notification settings - Fork 1
Examples
(Note that only @version
is required)
-- @description Display name/short description
-- @version 1.0.1
-- @author John Doe
-- @about
-- # Your Package's Title
--
-- Longer description/documentation for this package in *markdown*.
-- @changelog
-- Changed the button label to just "OK"
-- Fixed a typo in the popup dialog's text
reaper.ShowMessageBox("Hello World", "Script code here", 0)
Utility/Effect Name.jsfx
version: 1.0.5
desc: Display name/short description
author: John Doe
about:
# Your Package Title
Longer description and documentation for this package in *markdown*.
changelog:
- Added super cool feature XYZ
- Removed unused triggers
@init
@slider
@block
@sample
Extensions/Brain Interface.ext
@description Display name/short description
@version 1.0.5
@author John Doe
@about
# Your Package Title
Longer description/documentation for this package in *markdown*.
@changelog
- Added super cool feature XYZ
- Removed unused triggers
@provides
[darwin] reaper_braininterface.dylib http://example.com/download/$version/$path
[windows] reaper_braininterface.dll http://example.com/download/$version/$path
Category/author_Theme Name.theme
@description Theme Name
@version 1.0
@provides ThemeFile.ReaperThemeZip http://stash.reaper.fm/12345/$path
@author John Doe
@links
Forum Thread http://forum.cockos.com/showthread.php?t=175565
@screenshots
Arrange Window https://i.imgur.com/niDeNll.png
MIDI Editor https://i.imgur.com/cixprJ7.png
@about
Optionally write a description of your theme or some documentation here.
Translations/Klingon.ReaperLangPack
#NAME: LangPack Name
;Version: 1.0.1
;Author: John Doe
;Changelog: Fixed a typo
;About: Optionally write some text here (or remove this line)
[common]
DCEF2B4D03DE723C=Name
Web Interfaces/My Interface.www
@description Web Browser Interface Name
@author YourName
@version 1.0
@screenshot https://i.imgur.com/8NOddMK.png
@about Optionally write some text here (or remove this line)
@provides
my_interface/index.html
my_interface/*.{css,js,png}
Utility/Chord Names.data
@description Display name/short description
@version 1.0.5
@author John Doe
@provides Some Directory/*.txt
Add @noindex
or NoIndex: true
at the top of Library_File.lua and User_Callable_File.lua to prevent them from being also indexed.
-- @version 1.0
-- @provides
-- Library_File.lua
-- A Sub Directory/*.png
-- [main] User_Callable_File.lua
reaper.ShowMessageBox("Hello World", "Script code here", 0)
This will create a package containing two files without including itself (because of @metapackage
). Notice the lua comment syntax (--
) is not required in this case.
@description Name of the package
@version 1.0
@metapackage
@provides
[main] User Callable File1.lua
[main] User Callable File2.lua
The dot means "current file".
-- @description Name of the package
-- @version 1.0
-- @provides [nomain] .
function LibraryFunction()
end
@description Name of the package
@version 1.0
@provides . http://host.com/download/url/for/file1
@provides logo.png http://host.com/download/url/for/file2
This will install "Original.lua" in the repository as "Target/Name.lua".
-- @description Name of the package
-- @version 1.0
-- @provides Original.lua > Target/Name.lua
This will install the current file under multiple different filenames at once. get_action_context
is used to get the current filename and extract the slot number. The @metapackage
prevents the current file from being installed as-is so that only those created in the @provides
tag are.
See also Rename a file.
-- @version 1.0
-- @description Some nice script (3 slots)
-- @metapackage
-- @provides
-- [main] . > myname_Some nice script (slot 1).lua
-- [main] . > myname_Some nice script (slot 2).lua
-- [main] . > myname_Some nice script (slot 3).lua
local script_name = ({reaper.get_action_context()})[2]:match("([^/\\_]+)%.lua$")
local slot = tonumber(script_name:match("slot (%d+)"))
reaper.Undo_BeginBlock()
-- code here, using `slot` to determine what to do
reaper.Undo_EndBlock(script_name, 1)
Changelog can also be used as a regular tag in the first block like in the standard syntax. Note that the stars at the start of each line in the first block are only for esthetic purpose and are not required.
--[[
* ReaScript Name: Display name/short description
* Version: 1.0
* Author: John Doe
* About:
* Longer description/documentation for this package in *markdown*.
--]]
--[[
Changelog:
* v1.0
+ Initial release
--]]
reaper.ShowMessageBox("Hello World", "Script code here", 0)