User Tools

Site Tools


python

Python Scripting

  • Searching a File
  • Directory Search

config_directory=[]
with open("/etc/httpd/conf/httpd.conf", "r") as search_file:
    for line in search_file:
        if 'IncludeOptional' in line:
                config_directory.append(line)
                print config_directory[0]

python.txt · Last modified: (external edit)

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki