Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Projets publics
Sympa
Commits
44fd66eb
Unverified
Commit
44fd66eb
authored
Aug 07, 2019
by
IKEDA Soji
Committed by
GitHub
Aug 07, 2019
Browse files
Merge pull request #645 from ldidry/fix-637 by ldidry
Allow to activate pending lists with sympa.pl
parents
e89e1c13
e6be4989
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/sbin/sympa.pl.in
View file @
44fd66eb
...
...
@@ -87,7 +87,7 @@ unless (
'
send_digest
',
'
keep_digest
',
'
upgrade_config_location
',
'
role=s
',
'
dump_users
',
'
restore_users
',
'
open_list=s
',
'
open_list=s
',
'
show_pending_lists=s
'
)
)
{
pod2usage
(
-
exitval
=>
1
,
-
output
=>
\
*STDERR
);
...
...
@@ -1066,9 +1066,13 @@ elsif ($main::options{'sync_list_db'}) {
exit
1
;
}
my
$mode
=
'
open
';
$mode
=
'
install
'
if
$current_list
->
{'
admin
'}{'
status
'}
eq
'
pending
';
my
$spindle
=
Sympa::Spindle::
ProcessRequest
->
new
(
context
=>
$robot_id
,
action
=>
'
open_list
',
mode
=>
$mode
,
current_list
=>
$current_list
,
sender
=>
Sympa::
get_address
(
$robot_id
,
'
listmaster
'),
scenario_context
=>
{
skip
=>
1
},
...
...
@@ -1078,6 +1082,27 @@ elsif ($main::options{'sync_list_db'}) {
exit
1
;
}
exit
0
;
}
elsif
(
$
main::
options
{'
show_pending_lists
'})
{
my
$all_lists
=
Sympa::List::
get_lists
(
$
main::
options
{'
show_pending_lists
'},
'
filter
'
=>
['
status
'
=>
'
pending
']
);
if
(
@
{
$all_lists
})
{
print
"
Pending lists:
\n
";
foreach
my
$list
(
@$all_lists
)
{
printf
"
%s@%s
\n
subject: %s
\n
creator: %s
\n
date: %s
\n
",
$list
->
{'
name
'},
$
main::
options
{'
show_pending_lists
'},
$list
->
{'
admin
'}{'
subject
'},
$list
->
{'
admin
'}{'
creation
'}{'
email
'},
$list
->
{'
admin
'}{'
creation
'}{'
date_epoch
'};
}
}
else
{
printf
"
No pending list for robot %s
\n
",
$
main::
options
{'
show_pending_lists
'};
}
exit
0
;
}
die
'
Unknown option
';
...
...
@@ -1253,6 +1278,7 @@ S<[ C<--purge_list>=I<list>[I<@robot>] ]>
S<[ C<--lowercase> ]> S<[ C<--make_alias_file> ]>
S<[ C<--dump_users> C<--list>=I<list>@I<domain>|ALL [ C<--role>=I<roles> ] ]>
S<[ C<--restore_users> C<--list>=I<list>@I<domain>|ALL [ C<--role>=I<roles> ] ]>
S<[ C<--show_pending_lists>=I<robot> ]>
=head1 DESCRIPTION
...
...
@@ -1415,6 +1441,10 @@ users to DB (dump files in the list directory are imported).
Remove the list (remove archive, configuration files, users and owners in admin table. Restore is not possible after this operation.
=item C<--show_pending_lists>=I<robot>
Print all pending lists for the robot, with informations.
=item C<--reload_list_config>
[ C<--list=>I<mylist>@I<mydom> ] [ C<--robot=>I<mydom> ]
...
...
Write
Preview
Supports
Markdown
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