Skip to content

IMAGINARY/snapshot-slider

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

snapshot-slider

Controling the slider

You can either control the slider via mouse or touch screen or by using the hotkeys and .

Additional hotkeys are:

  • Mod+u: update the list of available SNAPSHOTs and reload
  • Mod+i: show simple About page
  • Mod+r: reload the slider without restarting the program (especially useful during development)
  • Mod+c: clear cache directories

Where Mod is Ctrl on Linux and Cmd on macOS.

How to build and run

You will need Node.js and npm.

On Ubuntu 14.04 and above, you can try the following procedure:

curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
sudo apt-get update
sudo apt-get install nodejs git libcups2-dev
sudo npm install --global yarn@1.7.0
git clone https://github.com/IMAGINRY/snapshot-slider
cd snapshot-slider
yarn install
yarn run start

Settings

Configuration data is stored inside a file called Settings located in the user data directory of the application. Depending on the platform, this defaults to

~/Library/Application Support/SNAPSHOT slider # macOS
~/.config/SNAPSHOT slider                     # Linux

The Settings file is in JSON format. It is created automatically, if it is not there.

Cache

SNAPSHOT PDF files are cached locally based on the urls supplied in the Settings file and stored in the application's cache directory.

The SNAPSHOT slider is able to detect corrupted files in the cache via sha256 hash sums and will attempt to download such files again. This will fail if there is no internet connection or the SNAPSHOT URLs supplied in the Settings file are invalid.

It is possible to clear the cache using the hotkey c.

Auto update

The SNAPSHOT slider can automatically update the list of available SNAPSHOT PDFs and download them to te cache. The default hotkey is u, but updates can also be performed on program startup. However, this is discouraged if the program is presented in a public, unsupervised venue since server errors can easily break the installation.

Building the redistributable packages

We rely on Electron builder to build the redistributable packages. Please see its documentation for prerequisites.

For Linux, also take a look at the Dockerfile and its dependencies (FROM) on dockerhub.

Now, you should be able to build the packages for your platform (only macOS and Linux supported at the moment):

yarn install
yarn run dist