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
REM Utilities | |
cinst 7zip | |
cinst vlc | |
cinst adobereader | |
cinst ccleaner | |
cinst filezilla | |
cinst dropbox | |
cinst virtualbox | |
cinst ChocolateyGUI | |
cinst windirstat |
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
values = ["value3", "value2", "value"] | |
length = len(values) | |
for ind, item in enumerate(values): | |
if ind + 1 != length: | |
if list[ind + 1] == "value": | |
print("Next one is the value") |
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
[Desktop Entry] | |
Version=1.0 | |
Encoding=UTF-8 | |
Name=Fritzing | |
GenericName=Fritzing | |
Comment=Interactive electronics designing software | |
Type=Application | |
Exec=/opt/fritzing/Fritzing | |
Icon=/opt/fritzing/fritzing_icon.png | |
Categories=Development |
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
[Desktop Entry] | |
Version=1.0 | |
Encoding=UTF-8 | |
Name=Energia | |
GenericName=Energia | |
Comment=Rapid prototyping softare for TI MCUs | |
Type=Application | |
Exec=/opt/energia/energia | |
Icon=/opt/energia/energia_icon.png | |
Categories=Development |
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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <stdbool.h> | |
typedef struct card { | |
unsigned int value; | |
struct card *next; | |
} Card_t; | |
static int AllocateCards(unsigned int numCards, Card_t **deckHead, Card_t **deckTail) { |
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 | |
# | |
# Install ansible and clone dotfiles. Ready to install machine | |
sudo add-apt-repository ppa:ansible/ansible | |
sudo apt-get update | |
sudo apt-get install git ansible python-pycurl | |
git clone https://github.com/zlalanne/dotfiles ~/.dotfiles |
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
text = re.sub(r'\.([a-zA-z])', r'. \1', text) |
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
def indent(elem, level=0): | |
"""Add whitespace to xml document to increase readability | |
elem - root element to start the indention at | |
level - start level of indention | |
""" | |
i = "\n" + level*" " | |
if len(elem): | |
if not elem.text or not elem.text.strip(): | |
elem.text = i + " " |
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
def load_json_data(json_filename): | |
""" | |
Load a *.json file into a Python dictionary | |
@param json_filename: path to the json file | |
@return: a dictionary containing the data | |
""" | |
json_file = open(json_filename) | |
json_data = json_file.read() | |
test_data = json.loads(json_data) |
OlderNewer