Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
projet
VPLPP
Commits
5ca5d6e8
Commit
5ca5d6e8
authored
Nov 19, 2020
by
Guillaume Huard
Browse files
Small renamings
parent
d6e7468f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Command_Line.org
View file @
5ca5d6e8
...
...
@@ -16,20 +16,20 @@
<p class=\"subtitle\">%a, %d</p>")))
#+END_SRC
Cette documentation présente le script =
case
in
e
= disponible à l'URL :
[[https://gricad-gitlab.univ-grenoble-alpes.fr/projet/vplpp/-/raw/master/caseine?inline=false][https://gricad-gitlab.univ-grenoble-alpes.fr/projet/vplpp/-/raw/master/
case
in
e
?inline=false]]
Cette documentation présente le script =
vpladm
in= disponible à l'URL :
[[https://gricad-gitlab.univ-grenoble-alpes.fr/projet/vplpp/-/raw/master/caseine?inline=false][https://gricad-gitlab.univ-grenoble-alpes.fr/projet/vplpp/-/raw/master/
vpladm
in?inline=false]]
permettant d'interagir avec un VPL depuis la ligne de commande.
* VPLID et /token/
Pour pouvoir interagir avec un VPL, deux choses sont nécessaires :
- un VPLID : le numéro du VPL, présent dans la partie réglages du VPL (/Edit settings/ puis dans
/Common module settings/. On peut le fournir à la commande =
case
in
e
= via la variable
d'environnement =
CASEINE_VPL
ID= ou via l'option =
vpl
id=.
/Common module settings/. On peut le fournir à la commande =
vpladm
in= via la variable
d'environnement =
VPLADMIN_
ID= ou via l'option =id=.
- un /token/ : spécifique à l'utilisateur, présent les infos utilisateur (/Profile/ puis /Security
keys/ via le menu de réglages) à la rubrique =VPL web service=). On peut le fournir à la commande
=
case
in
e
= via la variable d'environnement =
CASE
IN
E
_TOKEN= ou via l'option =token=.
=
vpladm
in= via la variable d'environnement =
VPLADM
IN_TOKEN= ou via l'option =token=.
* Commandes disponibles
Outre les options, le premier argument à donner à =
case
in
e
= est la commande à exécuter :
Outre les options, le premier argument à donner à =
vpladm
in= est la commande à exécuter :
case
in
e
→
vpladm
in
View file @
5ca5d6e8
...
...
@@ -8,8 +8,8 @@ $ENV{PERL_LWP_SSL_VERIFY_HOSTNAME}=0;
my
$url
=
'
https://moodle.caseine.org/webservice/rest/server.php
';
my
$debug
=
0
;
my
$json
=
0
;
my
$vplid
=
$ENV
{'
CASEINE_VPL
ID
'};
my
$token
=
$ENV
{'
CASE
IN
E
_TOKEN
'};
my
$vplid
=
$ENV
{'
VPLADMIN_
ID
'};
my
$token
=
$ENV
{'
VPLADM
IN_TOKEN
'};
sub
help
();
sub
failure
($);
...
...
@@ -75,11 +75,11 @@ my @commands = keys(%handlers);
sub
help
()
{
print
<<"END";
usage :
$0 [ --help ] [ --json ] [ --token value ] [ --
vpl
id value ] command [ arguments ]
$0 [ --help ] [ --json ] [ --token value ] [ --id value ] command [ arguments ]
Pushes data to caseine, where :
- token is the personnal token associated to the user of this script (by default, the value of the
CASE
IN
E
_TOKEN environment variable)
-
vpl
id is the id of the involved VPL (by default, the value of the
CASEINE_VPL
ID environment variable)
- token is the personnal token associated to the user of this script (by default, the value of the
VPLADM
IN_TOKEN environment variable)
- id is the id
number
of the involved VPL (by default, the value of the
VPLADMIN_
ID environment variable)
- the output is in JSON format is the --json option is given
- command is one of : @commands and its arguments are :
- filenames for save commands
...
...
@@ -98,7 +98,7 @@ sub failure($) {
}
GetOptions
('
help|h|?
'
=>
\
&help
,
'
vpl
id|
v
=s
'
=>
\
$vplid
,
'
id|
i
=s
'
=>
\
$vplid
,
'
token|t=s
'
=>
\
$token
,
'
debug|d
'
=>
\
$debug
,
'
json|j
'
=>
\
$json
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment