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
Sub ProgressBar() | |
' by dukenuke@newsmth.net | |
' Sun Jul 11 00:06:13 2010 | |
Dim mySlides As Slides | |
Dim pageBar As ShapeRange | |
Dim pageSHower As Shape | |
Dim pageWidth, pageHeight, pageStep | |
Set mySlides = Application.ActivePresentation.Slides |
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 <iostream> | |
#include <chrono> | |
#include <thread> | |
int main() | |
{ | |
//using namespace std::literals; | |
std::cout << "Hello waiter" << std::endl; | |
auto start = std::chrono::high_resolution_clock::now(); | |
std::this_thread::sleep_for (std::chrono::seconds(1)); | |
auto end = std::chrono::high_resolution_clock::now(); |
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 file: | |
2015-01-21-hello.md | |
2015-04-02-word.md | |
to: | |
hello.md | |
word.md | |
for f in 2015* ; do mv $f $(echo $f | sed 's/[0-9]\{4\}-[0-9]\{2\}-[0-9]\{2\}-//') ; 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
# Dark 256 color solarized theme for the color GNU ls utility. | |
# Used and tested with dircolors (GNU coreutils) 8.5 | |
# | |
# @author {@link http://sebastian.tramp.name Sebastian Tramp} | |
# @license http://sam.zoy.org/wtfpl/ Do What The Fuck You Want To Public License (WTFPL) | |
# | |
# More Information at | |
# https://github.com/seebi/dircolors-solarized |
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
# | |
# STL GDB evaluators/views/utilities - 1.03 | |
# | |
# The new GDB commands: | |
# are entirely non instrumental | |
# do not depend on any "inline"(s) - e.g. size(), [], etc | |
# are extremely tolerant to debugger settings | |
# | |
# This file should be "included" in .gdbinit as following: | |
# source stl-views.gdb or just paste it into your .gdbinit file |
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
" set F5 for compile and run c/cpp/python | |
"map <C-F5> : call CompileRunC()<CR> | |
map <F5> : call CompileRunCpp()<CR> | |
"map <F5>: call DebugCpp()<CR> | |
"map <F6> : call RunPython()<CR> | |
map <F6> : call RunShell()<CR> | |
func! CompileRunC() | |
exec "w" | |
exec "!gcc -std=c++11 -g -lboost_program_options -lpthread -lboost_system -lboost_filesystem % -o %<" |
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
spinner() { | |
local spin="\\|/-" | |
local i=0 | |
tput civis | |
while kill -0 "$1" 2>/dev/null; do | |
i=$(( (i+1) %4 )) | |
printf "\b%s" "${spin:$i:1}" | |
sleep 0.07 | |
done | |
tput cnorm |
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/expect | |
set timeout 20 | |
set cmd [lrange $argv 1 end] | |
set password [lindex $argv 0] | |
eval spawn $cmd | |
expect "assword:" | |
send "$password\r"; |
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
yum install yum-utils | |
# use --resolve to download dependencies. | |
yumdownloader --destdir ./rpms --resolve <package> | |
# on other machine | |
cd rpms | |
yum --disablerepo=* localinstall *.rpm -y |