forked from andreknieriem/photobooth
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.inc.php
49 lines (43 loc) · 1.42 KB
/
config.inc.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
$config = array();
$config['os'] = (DIRECTORY_SEPARATOR == '\\') || (strtolower(substr(PHP_OS, 0, 3)) === 'win') ? 'windows' : 'linux';
$config['dev'] = true;
$config['use_print'] = true;
$config['use_qr'] = true;
$config['show_fork'] = true;
#$config['file_format'] = 'date'; // comment in to get dateformat images
// FOLDERS
// change the folders to whatever you like
$config['folders']['images'] = 'images';
$config['folders']['thumbs'] = 'thumbs';
$config['folders']['qrcodes'] = 'qrcodes';
$config['folders']['print'] = 'print';
// GALLERY
// should the gallery list the newest pictures first?
$config['gallery']['newest_first'] = true;
// LANGUAGE
// possible values: en, de
$config['language'] = 'de';
// COMMANDS and MESSAGES
switch($config['os']) {
case 'windows':
$config['take_picture']['cmd'] = 'digicamcontrol\CameraControlCmd.exe /capture /filename %s';
$config['take_picture']['msg'] = 'Photo transfer done.';
$config['print']['cmd'] = 'mspaint /pt "%s"';
$config['print']['msg'] = '';
break;
case 'linux':
default:
$config['take_picture']['cmd'] = 'sudo gphoto2 --capture-image-and-download --filename=%s images';
$config['take_picture']['msg'] = 'New file is in location';
$config['print']['cmd'] = 'sudo lp -o landscape fit-to-page %s';
$config['print']['msg'] = '';
break;
}
// DON'T MODIFY
// preparation
foreach($config['folders'] as $directory) {
if(!is_dir($directory)){
mkdir($directory, 0777);
}
}