Skip to content

Instantly share code, notes, and snippets.

@sixstringsg
sixstringsg / gist:3785697
Created September 26, 2012 02:41
thumbnail conversion
FOLDER=images/
i=0
for file in $FOLDER; do
i=$[i+1]
mv $file $i.jpg
cp $i.jpg thumbs/
done
cd thumbs
Process: VLC [1453]
Path: /Volumes/VOLUME/VLC.app/Contents/MacOS/VLC
Identifier: org.videolan.vlc
Version: 2.0.3 (2.0.3)
Code Type: X86-64 (Native)
Parent Process: launchd [277]
User ID: 501
Date/Time: 2012-09-25 23:10:22.430 -0500
OS Version: Mac OS X 10.8.2 (12C54)
<a href="imgs/space/Universe_and_planets_digital_art_wallpaper_denebola.jpg" class="thumb_link"><span class="selected"></span><img src="imgs/space/Universe_and_planets_digital_art_wallpaper_denebola_thumb.jpg" title="Denebola" alt="Denebola" class="thumb" /></a>
Process: VLC [2761]
Path: /Applications/VLC.app/Contents/MacOS/VLC
Identifier: org.videolan.vlc
Version: 2.0.4 (2.0.4)
Code Type: X86-64 (Native)
Parent Process: launchd [277]
User ID: 501
Date/Time: 2012-09-26 16:56:12.118 -0500
OS Version: Mac OS X 10.8.2 (12C54)
#!/bin/bash
export PATH="/usr/lib/ccache:$PATH"
export USE_CCACHE=1
export CCACHE_DIR=/share/ccache
export CCACHE_COMPRESS=1
export CCACHE_UMASK=002
if [ "$(id -gn)" == "ccache" ];then
ccache -M 150G;
fi
@sixstringsg
sixstringsg / khas_is_a_slacker.sh
Created October 12, 2012 17:30 — forked from KhasMek/khas_is_a_slacker.sh
not another image manipulation script. xD
#!/bin/bash
#
# Image template creator and thumbnail maker.
#
# USAGE: ./make_lazy $CUSTOM_TITLE_NAME
# If CUSTOM_TITLE_NAME is blank, it will use the actual filename
# (with underscores and all).
# Currently supported formats are .png and .jpg.
#
# In addition to most normal linux apps, this script will
@sixstringsg
sixstringsg / gist:4457190
Created January 4, 2013 21:45
N7000 make error
p:19:
frameworks/native/include/ui/GraphicBuffer.h:69:35: error: 'GRALLOC_USAGE_HW_FIMC1' was not declared in this scope
cc1plus: warning: command line option '-std=gnu99' is valid for C/ObjC but not for C++ [enabled by default]
cc1plus: warning: command line option '-std=gnu99' is valid for C/ObjC but not for C++ [enabled by default]
In file included from frameworks/native/include/gui/ISurfaceTexture.h:29:0,
from frameworks/base/media/mca/filterfw/native/core/gl_env.h:30,
from frameworks/base/media/mca/filterfw/native/core/vertex_frame.cpp:19:
frameworks/native/include/ui/GraphicBuffer.h:69:35: error: 'GRALLOC_USAGE_HW_FIMC1' was not declared in this scope
target thumb C: libsuspend <= system/core/libsuspend/autosuspend.c
realmake: *** [out/target/product/n7000/obj/STATIC_LIBRARIES/libfilterfw_native_intermediates/core/gl_env.o] Error 1
target asm: static_busybox <= external/busybox/android/libc/arch-arm/syscalls/stime.S
target asm: static_busybox <= external/busybox/android/libc/arch-arm/syscalls/getsid.S
target asm: static_busybox <= external/busybox/android/libc/arch-arm/syscalls/adjtimex.S
Install: /home/sixstringsg/AOKP/out/target/product/n7000/fake_packages/charger_res_images-timestamp
Copy: out/target/product/n7000/system/media/bootanimation.zip
Copy xml: out/target/product/n7000/system/etc/permissions/com.tmobile.software.themes.xml
Copy: out/target/product/n7000/system/bin/sysinit
Copy: out/target/product/n7000/system/etc/sysctl.conf
Copy: out/target/product/n7000/system/etc/init.d/01sysctl
Copy: out/target/product/n7000/system/etc/init.d/00start
sixstringsg@jarvis:~$ javac -g /home/sixstringsg/Documents/rover_controller.java
/home/sixstringsg/Documents/rover_controller.java:25: error: cannot find symbol
static Client myClient;
^
symbol: class Client
location: class rover_controller
/home/sixstringsg/Documents/rover_controller.java:41: error: cannot find symbol
myClient = new Client(port, dataport, host, rev);
^
symbol: class Client
pi@mark1 ~/RaspberryRover $ g++ main.cpp
main.cpp: In function ‘int main(int, char**)’:
main.cpp:146:12: error: ‘leftReverse’ was not declared in this scope
deleting line 146 with leftReverse fixed the above error, but I'm sure that's not the correct way.
pi@mark1 ~/RaspberryRover $ nano main.cpp
pi@mark1 ~/RaspberryRover $ g++ main.cpp
/tmp/ccTt5h3J.o: In function `main':
main.cpp:(.text+0x1c): undefined reference to `wiringPiSetupGpio'