Example #1
0
def open_config_folder():
    """Calling this function opens the pydna configuration folder in
    the default file manager. The location for this folder is stored
    in the *pydna_config_dir* environmental variable.

    The `pydna.ini` file can be edited to make pydna quicker to use.
    See the documentation of the :class:configparser.ConfigParser´ class.

    Below is the content of a typical `pydna.ini` file on a Linux
    system.

    ::

        [main]
        loglevel=30
        [email protected]
        data_dir=/home/bjorn/.local/share/pydna
        log_dir=/home/bjorn/.cache/pydna/log
        ape=tclsh /home/bjorn/.ApE/apeextractor/ApE.vfs/lib/app-AppMain/AppMain.tcl
        cached_funcs=Genbank_nucleotide
        primers=/home/bjorn/Dropbox/wikidata/PRIMERS.txt
        enzymes=/home/bjorn/Dropbox/wikidata/RestrictionEnzymes.txt

    The email address is set to [email protected] by default. If you change this
    to you own address, the :func:`pydna.genbank.genbank` function can be used
    to download sequences from Genbank directly without having to explicitly add
    the email address.

    Pydna can cache results from the following functions or methods:

    - :func:`pydna.genbank.Genbank.nucleotide`   Genbank_nucleotide
    - :func:`pydna.amplify.Anneal`               amplify_Anneal
    - :func:`pydna.assembly.Assembly`            assembly_Assembly
    - :func:`pydna.download.download_text`       download.download_text
    - :func:`pydna.dseqrecord.Dseqrecord.synced` Dseqrecord_synced

    These can be added separated by a comma to the cached_funcs entry in **pydna.ini**
    file or the pydna_cached_funcs environment variable.

    """
    return _open_folder(_os.environ["pydna_config_dir"])
Example #2
0
def open_log_folder():
    return _open_folder(_os.environ["pydna_log_dir"])
Example #3
0
def open_cache_folder():
    """Calling this function opens the pydna cache folder in
    the default file manager. The location for this folder is stored
    in the *pydna_data_dir* environmental variable."""
    return _open_folder(_os.environ["pydna_data_dir"])
Example #4
0
def open_current_folder():
    """Calling this function opens the current working directory
    in the default file manager. The location for this folder is
    given by the :func:`os.getcwd` function"""
    return _open_folder(_os.getcwd())