Skip to content

Latest commit

 

History

History
102 lines (73 loc) · 3.51 KB

README.md

File metadata and controls

102 lines (73 loc) · 3.51 KB

The File Actions app is a scripting tool, which administrators can employ to automate workflows and to give users of the Nextcloud instance additional custom file actions. The actions are accessible straight from the Files app!

🌕 Scripting in Lua, it's simple and has plenty of online resources.
Make hard tasks easy, straight from the Files app.
🙋 Are you missing a function in the scripting API? Open an issue on Github!
🤖 Integration with Nextcloud Flow allows you to fully automate workflows.

Screenshot of Files Scripts Version 1.0.0

Installation & Configuration

Required:

  • Nextcloud >=23
  • PHP >=7.4

Recommended:

The app includes a Lua interpreter which runs on PHP. This interpreter is still under development and its use is not recommended. For a faster and more reliable solution, install the Lua PHP extension.

  • Lua + PHP Lua plugin
sudo apt-get install lua5.3
sudo apt-get install liblua5.3-0
sudo apt-get install liblua5.3-dev
Lua plugin for PHP 7
sudo apt-get install php-pear
sudo apt-get install php7-dev

sudo cp /usr/include/lua5.3/lua.h /usr/include
sudo ln -s /usr/include/lua5.3/ /usr/include/lua
sudo cp /usr/lib/x86_64-linux-gnu/liblua5.3.a /usr/lib/liblua.a
sudo cp /usr/lib/x86_64-linux-gnu/liblua5.3.so /usr/lib/liblua.so

sudo pecl install lua-2.0.7
Lua plugin for PHP 8 Since the Lua plugin is not yet officially supported for PHP8, we need to build it.
sudo apt-get install php-pear
sudo apt-get install php-dev

cd ~
git clone https://github.com/badoo/php-lua.git
cd php-lua
phpize && ./configure --with-lua-version=5.3
make

# The destination path may change depending on your PHP version
# You can find your extension directory by using:
# php -i | grep extension_dir
sudo cp ./.libs/lua.so /usr/lib/php/20200930/

Don't forget to append extension=lua.so to your php.ini!

Optional:

Some functions require additional packages to be installed on the server.
sudo apt-get install qpdf
sudo apt install ffmpeg

Documentation

The admin documentation contains information about how to create new actions and some precautions that should be taken when writing one.

The scripting API documentation contains descriptions for all the API functions as well as some snippets of how they can be used.

Contributing

Contributions to the app are most welcome!

  • 🌍 Translations
    The app can be translated through the Nextcloud community in Transifex
  • 🛠 Scripting API
    If there is something you need that is currently not possible (or complex) to do with scripting API, please open a GitHub issue, or even better, a pull request!
  • 📃 Documentation
    The app and API are constantly evolving and the documentation can always be improved. If you have any suggestions or improvements, please do help out!
  • 💸 Donations
    Last and least, you can donate your hard-earned cash with Liberapay.