diff options
Diffstat (limited to 'makescripts/systeminstall.py')
-rw-r--r-- | makescripts/systeminstall.py | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/makescripts/systeminstall.py b/makescripts/systeminstall.py deleted file mode 100644 index faad71e..0000000 --- a/makescripts/systeminstall.py +++ /dev/null @@ -1,52 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- -# -# Copyright (C) 2012 S. Daniel Francis <francis@sugarlabs.org> -# -# 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, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301, USA. - -import sys -import os -import pwd -sys.path.append(os.path.abspath('./')) -import info -user = pwd.getpwuid(os.getuid()).pw_name - -if user == 'root': - os.system('cp makescripts/command.py /usr/bin/%s' % info.lower_name) - try: - os.mkdir('/usr/share/%s' % info.lower_name) - os.mkdir('/usr/share/%s/icons' % info.lower_name) - except: - pass - os.system('cp -R desktop/sweetener /usr/share/%s/sweetener' %\ - info.lower_name) - os.system('cp data/* /usr/share/%s/' % info.lower_name) - os.system('cp *.py /usr/share/%s/' % info.lower_name) - os.system('cp desktop/icons/*.svg /usr/share/%s/icons' %\ - info.lower_name) - os.system('cp %s.png /usr/share/%s/' % (info.lower_name, - info.lower_name)) - for i in os.listdir('locale'): - if not os.path.exists(os.path.join('/usr/share/locale', i)): - os.mkdir(os.path.join('/usr/share/locale', i)) - if not os.path.exists(os.path.join('/usr/share/locale', i, - 'LC_MESSAGES')): - os.mkdir(os.path.join('/usr/share/locale', i, - 'LC_MESSAGES')) - os.system( - 'cp locale/%n%/LC_MESSAGES/*.mo /usr/share/locale/%n%/LC_MESSAGES/'.replace( - '%n%', i)) |