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
" DESC: Save file if it modified and run python code | |
fun! pymode#run#JumpToCurrentError() "{{{ | |
let a:err = [] | |
sil!substitute /File\s\"\(.*\)\"\zs/\=add(a:err, submatch(1))[1:0]/ | |
sil!substitute /,\sline\s\(\d\+\)\zs/\=add(a:err,submatch(1))[1:0]/ | |
wincmd k | |
if len(a:err) > 0 | |
if filereadable(fnamemodify('.', ':p') . a:err[0]) | |
exe "next " . fnamemodify('.', ':p') . a:err[0] | |
exe "normal " . a:err[1] . "gg" |
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
package nl.tudelft.dmirlab.pydo; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.io.InputStreamReader; | |
import java.io.OutputStream; | |
public class Bashtest { |
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 bash | |
if [[ $# < 2 ]]; then | |
echo "Usage: watchdog <pcs> <email>" | |
exit 1 | |
fi | |
svr="$(hostname)" | |
pcs=$1 | |
pcsdetail=$(ps --no-heading -p $pcs) |
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
diff --git a/pylibs/pylama/pylint/checkers/logging.py b/pylibs/pylama/pylint/checkers/logging.py | |
index 4c78d8f..f25b893 100644 | |
@@ -90,6 +90,8 @@ class LoggingChecker(checkers.BaseChecker): | |
and ancestor.parent.name == 'logging')])] | |
except astng.exceptions.InferenceError: | |
return | |
+ except AttributeError: | |
+ return | |
if (node.func.expr.name != self._logging_name and not logger_class): | |
return |
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 | |
# -*- coding: utf-8 -*- | |
""" | |
File: ljson2mongo.py | |
Author: SpaceLis | |
Email: Wen.Li@tudelft.nl |
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 | |
# -*- coding: utf-8 -*- | |
""" | |
File: stratified.py | |
Author: SpaceLis | |
Email: Wen.Li@tudelft.nl | |
Github: http://github.com/spacelis | |
Description: | |
Sampling in a stratified way. That is sampling from each subpopulation to | |
make the sample set more representative than simple random sampling. For |
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 | |
# -*- coding: utf-8 -*- | |
""" Testing API module. | |
File: test_api.py | |
Author: SpaceLis | |
Email: Wen.Li@tudelft.nl | |
GitHub: http://github.com/spacelis | |
Description: | |
Testing API Module. |
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
EMAILPTN = re.compile("^[-!#$%&'*+/0-9=?A-Z^_a-z{|}~]" | |
"(\.?[-!#$%&'*+/0-9=?A-Z^_a-z{|}~])*" | |
"@[a-zA-Z](-?[a-zA-Z0-9])*" | |
"(\.[a-zA-Z](-?[a-zA-Z0-9])*)+$") |
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
--- __init__.old.py 2014-10-07 01:26:24.682034979 +0200 | |
+++ __init__.py 2014-10-07 01:26:30.558034775 +0200 | |
@@ -4272,7 +4272,7 @@ | |
return self.imshow(imread(urllib2.urlopen(basemap_url)),origin='upper') | |
def wmsimage(self,server,\ | |
- xpixels=400,ypixels=None,\ | |
+ xpixels=400,ypixels=None,togray=False,\ | |
format='png',verbose=False,**kwargs): | |
""" |
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
--- __init__.py.old 2014-10-07 01:26:24.682034979 +0200 | |
+++ __init__.py 2014-10-07 14:48:02.542868362 +0200 | |
@@ -4272,7 +4272,7 @@ | |
return self.imshow(imread(urllib2.urlopen(basemap_url)),origin='upper') | |
def wmsimage(self,server,\ | |
- xpixels=400,ypixels=None,\ | |
+ xpixels=400,ypixels=None,togray=False,\ | |
format='png',verbose=False,**kwargs): | |
""" |
OlderNewer