This file contains hidden or 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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE language SYSTEM "language.dtd"> | |
<!-- | |
This file is part of KDE's kate project. | |
copyright : (C) 2015 by Fredrik Persson | |
email : [email protected] | |
This file is free software; you can redistribute it and/or modify | |
it under the terms of the GNU General Public License as published by |
This file contains hidden or 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
#!/bin/bash | |
############################################ | |
# Name: create.sh | |
# Usage: ./create.sh app-name | |
############################################ | |
PROJECTNAME=$1 | |
WORKINGDIR=$HOME/development/$PROJECTNAME | |
SRCDIR=$WORKINGDIR/src |
This file contains hidden or 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
#!/bin/bash | |
TMPFILE="/tmp/gitstat.txt" | |
FILENAME="/tmp/gitstat_files.txt" | |
if [ -d $1 ] ; then | |
if [ -f $2 ] ; then | |
rm $2 | |
fi | |
This file contains hidden or 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
import pycurl | |
import json | |
from StringIO import StringIO | |
from pprint import pprint | |
buffer = StringIO() | |
c = pycurl.Curl() | |
c.setopt(c.URL, 'https://api.github.com/users/fpersson/gists') | |
c.setopt(c.WRITEFUNCTION, buffer.write) | |
c.perform() |
This file contains hidden or 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 <string> | |
#include <iostream> | |
#include <stdio.h> | |
/** | |
* This is not tested in windows. | |
* Windows users should use _popen and _pclose. | |
* http://msdn.microsoft.com/en-us/library/aa298534(v=vs.60).aspx | |
*/ |
This file contains hidden or 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 <iostream> | |
#include <array> | |
int main(){ | |
//col, row | |
std::array<std::array<int, 10>, 10> mymap{{ | |
{{1,2,3,4,5,6,7,8,9,0}}, | |
{{1,2,3,4,5,6,7,8,9,0}}, | |
{{1,2,3,4,5,6,7,8,9,0}}, | |
{{1,2,3,4,5,6,7,8,9,0}}, |
This file contains hidden or 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
/** | |
* best and easiest way... improvement can still be done ;) | |
*/ | |
bool wortdateoOeffnen(){ | |
bool openSuccess = false | |
string Dateiort; | |
cout << "Bitte die Datei inklusive Pfad angeben" << endl; | |
//Text noch rot machen | |
cout << "ACHTUNG: Bei Windows bitte / (Slash) mit \ (Backslash) austauschen " << endl << endl ; | |
cout << "---> "; |
This file contains hidden or 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 <iostream> | |
#include <fstream> | |
/** | |
* @brief a quick sample code to answare a beginers question about file paths in C++, this code is free to use for anyone. | |
*/ | |
class Path{ | |
public: | |
Path(std::string path, std::string file); | |
This file contains hidden or 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 <iostream> | |
#include <fstream> | |
#include <string> | |
#include <chrono> | |
#include <ctime> | |
class FLog{ | |
public: | |
FLog(std::string logfile); | |
This file contains hidden or 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 <iostream> | |
#include <string> | |
#include <map> | |
enum TMemoryValue{YES=1, NO, MAYBE, UNKNOWN}; | |
int main () { | |
std::map<std::string, TMemoryValue> memorymap; | |
std::map<std::string, TMemoryValue>::iterator it; | |