if re.search(p.packageString(), keywordfilecontent): print((p.packageString() + " already in package.keywords.")) else: keywordfile.write("\n" + p.packageString() + "\n") print(("Appended " + p.packageString()+ " to /etc/portage/package.keywords/arch")) keywordfile.close() else: print("You are not root, your unmaskstring would be:") print(("\n".join([p.packageString() for p in packs]) + "\n")) ## Write the scripts writeUSE(jobname, packs, config["ignoreprefix"]) writeRdeps(jobname, packs) if options.bugnum: writeSuccess(jobname, options.bugnum, config["successmessage"]) exit (0) ## If we arrive here then a package atom should be given try: pack = gP(args[0]) except IndexError: print("Please call with package atom as argument") exit (1) if options.depend: writerdepscript(pack) if options.usecombi: writeusecombiscript(pack) ## That's all folks ##
print((p.packageString() + " already in package.keywords.")) else: keywordfile.write("\n" + p.packageString() + "\n") print(("Appended " + p.packageString() + " to /etc/portage/package.keywords/arch")) keywordfile.close() else: print("You are not root, your unmaskstring would be:") print(("\n".join([p.packageString() for p in packs]) + "\n")) ## Write the scripts writeUSE(jobname, packs, config["ignoreprefix"]) writeRdeps(jobname, packs) if options.bugnum: writeSuccess(jobname, options.bugnum, config["successmessage"]) exit(0) ## If we arrive here then a package atom should be given try: pack = gP(args[0]) except IndexError: print("Please call with package atom as argument") exit(1) if options.depend: writerdepscript(pack) if options.usecombi: writeusecombiscript(pack) ## That's all folks ##
import sys sys.path.append('../tatt') from scriptwriter import * from gentooPackage import gentooPackage as gP print(useCombiTestString(gP("=media-sound/amarok-2.3.1-r2"), []))
import sys sys.path.append('../tatt') from scriptwriter import * from gentooPackage import gentooPackage as gP print(useCombiTestString(gP("=media-sound/amarok-2.3.1-r2"),[]))