This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo add-apt-repository ppa:santilli-gabriele/slic3r-prusa | |
sudo apt-get update | |
sudo apt install slic3r-prusa | |
# source | |
## http://shop.prusa3d.com/forum/original-prusa-i3-mk2-f23/ubuntu-ppa-for-slic3r-prusa-edition-t3042.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0x0E62556027f7371DA69001b7331039A42D0EB63C |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from contextlib import contextmanager | |
import sys, os | |
@contextmanager | |
def suppress_stdout(): | |
""" | |
source: https://gist.github.com/djsmith42/3956189 | |
usage: | |
print "You can see this" | |
with suppress_stdout(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from contextlib import contextmanager | |
import sys, os | |
@contextmanager | |
def suppress_stdout(): | |
with open(os.devnull, "w") as devnull: | |
old_stdout = sys.stdout | |
sys.stdout = devnull | |
try: | |
yield |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from __future__ import print_function | |
__author__ = 'github.com/ruxi' | |
__license__= 'MIT' | |
import sys | |
import os.path | |
import subprocess | |
def runbash(cmd, cwd=".", shell=True, logname="runbash.log", ioprint=True): | |
""" | |
cmd: bash command to run. example: 'ls -l' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Rename all *.fasta to *.sra | |
for f in *.fasta; do | |
mv -- "$f" "${f%.fasta}.sra" | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
__author__ = "github.com/ruxi" | |
__license__ = "MIT" | |
import requests | |
import tqdm # progress bar | |
import os.path | |
def download_file(url, filename=False, verbose = False): | |
""" | |
Download file with progressbar | |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.