add initial files
This commit is contained in:
71
dev.unraid-ox.plg
Normal file
71
dev.unraid-ox.plg
Normal file
@@ -0,0 +1,71 @@
|
||||
<?xml version='1.0' standalone='yes'?>
|
||||
<!DOCTYPE PLUGIN [
|
||||
<!ENTITY name "unraid-dust">
|
||||
<!ENTITY author "dtomlinson">
|
||||
<!ENTITY org "dtomlinson91">
|
||||
<!ENTITY version "v0.8.0">
|
||||
<!ENTITY gitURL "https://git.panaetius.co.uk/&org;/&name;">
|
||||
<!ENTITY pluginURL "&gitURL;/raw/branch/master/&name;.plg">
|
||||
<!ENTITY releaseURL "&gitURL;/releases/download/&version;/&name;-&version;.txz">
|
||||
<!ENTITY md5 "94f4ef1e48660aab84fe0aa2e385513a">
|
||||
<!ENTITY plugin "/boot/config/plugins/&name;">
|
||||
<!ENTITY emhttp "/usr/local/emhttp/plugins/&name;">
|
||||
]>
|
||||
|
||||
<PLUGIN name="&name;" author="&author;" version="&version;" pluginURL="&pluginURL;" min="6.8.3">
|
||||
|
||||
<CHANGES>
|
||||
|
||||
### 2022-05-06
|
||||
|
||||
- Initial release - dust v0.8.0
|
||||
|
||||
</CHANGES>
|
||||
|
||||
<FILE Run="/bin/bash">
|
||||
<INLINE>
|
||||
<!-- remove previous version if present -->
|
||||
file=$(/usr/bin/ls /boot/config/plugins/&name;/&name;*.txz | grep -v '&version;')
|
||||
if [ ! -z "$file" ]
|
||||
then
|
||||
filename=$(basename -- $file)
|
||||
previous="${filename%.*}"
|
||||
echo "previous version ${previous} found - uninstalling"
|
||||
removepkg $previous
|
||||
rm -f $file
|
||||
else
|
||||
echo "no previous version found - first time install"
|
||||
fi
|
||||
</INLINE>
|
||||
</FILE>
|
||||
|
||||
<FILE Name="/boot/config/plugins/&name;/&name;-&version;.txz" Run="upgradepkg --install-new">
|
||||
<URL>&releaseURL;</URL>
|
||||
<MD5>&md5;</MD5>
|
||||
</FILE>
|
||||
|
||||
<FILE Name="&emhttp;/README.md">
|
||||
<INLINE>
|
||||
**ox**
|
||||
|
||||
Ox is a code editor that runs in your terminal.
|
||||
|
||||
For more information see the [ox repository](https://github.com/curlpipe/ox).
|
||||
</INLINE>
|
||||
</FILE>
|
||||
|
||||
<FILE Run="/bin/bash" Method="remove">
|
||||
<INLINE>
|
||||
echo "*** Removing dust ***"
|
||||
|
||||
# Remove plugin related files
|
||||
removepkg &name;-&version;
|
||||
|
||||
rm -rf &emhttp;
|
||||
rm -rf &plugin;
|
||||
|
||||
echo
|
||||
echo "*** Successfully removed dust ***"
|
||||
</INLINE>
|
||||
</FILE>
|
||||
</PLUGIN>
|
||||
Reference in New Issue
Block a user