2015-06-23 23:07:03 +02:00
|
|
|
#
|
|
|
|
# The Qubes OS Project, https://www.qubes-os.org/
|
|
|
|
#
|
|
|
|
# Copyright (C) 2015 Joanna Rutkowska <joanna@invisiblethingslab.com>
|
|
|
|
# Copyright (C) 2015 Wojtek Porczyk <woju@invisiblethingslab.com>
|
|
|
|
#
|
2017-10-12 00:11:50 +02:00
|
|
|
# This library is free software; you can redistribute it and/or
|
|
|
|
# modify it under the terms of the GNU Lesser General Public
|
|
|
|
# License as published by the Free Software Foundation; either
|
|
|
|
# version 2.1 of the License, or (at your option) any later version.
|
2015-06-23 23:07:03 +02:00
|
|
|
#
|
2017-10-12 00:11:50 +02:00
|
|
|
# This library is distributed in the hope that it will be useful,
|
2015-06-23 23:07:03 +02:00
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
2017-10-12 00:11:50 +02:00
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
# Lesser General Public License for more details.
|
2015-06-23 23:07:03 +02:00
|
|
|
#
|
2017-10-12 00:11:50 +02:00
|
|
|
# You should have received a copy of the GNU Lesser General Public
|
|
|
|
# License along with this library; if not, see <https://www.gnu.org/licenses/>.
|
2015-06-23 23:07:03 +02:00
|
|
|
#
|
|
|
|
|
2018-09-12 01:50:24 +02:00
|
|
|
'''qubes-create - Create new Qubes OS store'''
|
2015-06-23 23:07:03 +02:00
|
|
|
|
2015-10-05 23:46:25 +02:00
|
|
|
import sys
|
2015-06-23 23:07:03 +02:00
|
|
|
import qubes
|
2015-06-24 16:42:06 +02:00
|
|
|
import qubes.tools
|
2015-06-23 23:07:03 +02:00
|
|
|
|
2015-10-05 13:46:06 +02:00
|
|
|
parser = qubes.tools.QubesArgumentParser(
|
2015-10-05 17:34:13 +02:00
|
|
|
description='Create new Qubes OS store.',
|
|
|
|
want_app=True,
|
|
|
|
want_app_no_instance=True)
|
2015-06-23 23:07:03 +02:00
|
|
|
|
|
|
|
def main(args=None):
|
|
|
|
'''Main routine of :program:`qubes-create`.
|
|
|
|
|
|
|
|
:param list args: Optional arguments to override those delivered from \
|
|
|
|
command line.
|
|
|
|
'''
|
|
|
|
|
|
|
|
args = parser.parse_args(args)
|
2016-11-02 17:30:27 +01:00
|
|
|
qubes.Qubes.create_empty_store(args.app,
|
2017-05-11 21:24:20 +02:00
|
|
|
offline_mode=args.offline_mode)
|
2015-12-28 18:14:37 +01:00
|
|
|
return 0
|
2015-06-23 23:07:03 +02:00
|
|
|
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
2015-12-28 18:14:37 +01:00
|
|
|
sys.exit(main())
|