1
0
mirror of https://github.com/samba-team/samba.git synced 2025-04-30 18:53:31 +03:00
Giampaolo Lauria f6fa868489 samba-tool: moved takes_optiongroups definition to Command base class
The option groups should be defined at the Command base class level as they are in common across all samba-tool commands.
Major move advantages:
1. more OOP approach
2. enforcing consistency across commands
3. avoiding the need of declaring for every new command

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-21 10:32:24 +10:00

35 lines
1.1 KiB
Python

#!/usr/bin/env python
#
# Manipulate ACLs
#
# Copyright (C) Matthieu Patou <mat@matws.net> 2010
# Copyright (C) Nadezhda Ivanova <nivanova@samba.org> 2010
# Copyright Giampaolo Lauria 2011 <lauria2@yahoo.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
from samba.netcmd import (
SuperCommand,
)
from samba.netcmd.ntacl import cmd_nt_acl
from samba.netcmd.dsacl import cmd_ds_acl
class cmd_acl(SuperCommand):
"""NT ACLs manipulation"""
subcommands = {}
subcommands["nt"] = cmd_nt_acl()
subcommands["ds"] = cmd_ds_acl()