forked from ClioPatria/ClioPatria
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun.pl.in
executable file
·67 lines (45 loc) · 2.04 KB
/
run.pl.in
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
@HASHBANG@@SWIPL@ @LOADOPTIONS@
:- initialization cp_server.
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
This file provides a skeleton startup file. It can be localized by running
% ./configure (Unix)
% Double-clicking win-config.exe (Windows)
After that, the system may be customized by copying or linking
customization files from config-available to config-enabled. See
config-enabled/README.txt for details.
To run the system, do one of the following:
* Running for development
Run ./run.pl (Unix) or open run.pl by double clicking it (Windows)
* Running as Unix daemon (service)
See daemon.pl
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
% Setup search path for cliopatria. We add both a relative and absolute
% path. The absolute path allow us to start in any directory, while the
% relative one ensures that the system remains working when installed on
% a device that may be mounted on a different location.
add_relative_search_path(Alias, Abs) :-
is_absolute_file_name(Abs), !,
prolog_load_context(file, Here),
relative_file_name(Abs, Here, Rel),
assertz(user:file_search_path(Alias, Rel)).
add_relative_search_path(Alias, Rel) :-
assertz(user:file_search_path(Alias, Rel)).
file_search_path(cliopatria, '@CLIOPATRIA@').
:- add_relative_search_path(cliopatria, '@CLIOPATRIA@').
% Make loading files silent. Comment if you want verbose loading.
:- current_prolog_flag(verbose, Verbose),
asserta(saved_verbose(Verbose)),
set_prolog_flag(verbose, silent).
/*******************************
* LOAD CODE *
*******************************/
% Use the ClioPatria help system. May be commented to disable online
% help on the source-code.
:- use_module(cliopatria('applications/help/load')).
% Load ClioPatria itself. Better keep this line.
:- use_module(cliopatria(cliopatria)).
% Get back normal verbosity of the toplevel.
:- ( retract(saved_verbose(Verbose))
-> set_prolog_flag(verbose, Verbose)
; true
).