Skip to content

Instantly share code, notes, and snippets.

aghasoroush

  • TeemSheem
Block or report user

Report or block aghasoroush

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View mgoExample.go
package main
import (
"fmt"
"labix.org/v2/mgo"
"labix.org/v2/mgo/bson"
"time"
)
type Person struct {
@aghasoroush
aghasoroush / spring.MD
Last active Nov 20, 2017
spring-boot-tips
View spring.MD

Spring Boot your Hello World app will not "start"

add this to dependencies

<dependency>
   <groupId>org.springframework.boot</groupId>
   <artifactId>spring-boot-starter-web</artifactId>
</dependency>
@aghasoroush
aghasoroush / Linux Static IP
Created Jan 29, 2016 — forked from fernandoaleman/Linux Static IP
How To Configure Static IP On CentOS 6
View Linux Static IP
## Configure eth0
#
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE="eth0"
NM_CONTROLLED="yes"
ONBOOT=yes
HWADDR=A4:BA:DB:37:F1:04
TYPE=Ethernet
BOOTPROTO=static
@aghasoroush
aghasoroush / winroute.py
Created Nov 29, 2015
A simple class for working with Windows routes
View winroute.py
import subprocess
class RouteEntity(object):
def __init__(self, data):
self.data = data
@property
def destination(self):
return self.data[0]
View centos-install-casperjs
wget https://phantomjs.googlecode.com/files/phantomjs-1.9.1-linux-x86_64.tar.bz2
bunzip2 phantomjs-1.9.1-linux-x86_64.tar.bz2
tar xf phantomjs-1.9.1-linux-x86_64.tar
mv phantomjs-1.9.1-linux-x86_64/ /opt/
ln -s /opt/phantomjs-1.9.1-linux-x86_64/ /opt/phantomjs
ln -s /opt/phantomjs/bin/phantomjs /usr/local/bin/
#check what you've just done
which phantomjs
phantomjs --version
View centos-install-casperjs
wget https://phantomjs.googlecode.com/files/phantomjs-1.9.1-linux-x86_64.tar.bz2
bunzip2 phantomjs-1.9.1-linux-x86_64.tar.bz2
tar xf phantomjs-1.9.1-linux-x86_64.tar
mv phantomjs-1.9.1-linux-x86_64/ /opt/
ln -s /opt/phantomjs-1.9.1-linux-x86_64/ /opt/phantomjs
ln -s /opt/phantomjs/bin/phantomjs /usr/local/bin/
#check what you've just done
which phantomjs
phantomjs --version
View gist:8590703
cd;
wget http://www.open.com.au/mikem/bcm2835/bcm2835-1.3.tar.gz;
tar xvfz bcm2835-1.3.tar.gz;
cd bcm2835-1.3;
./configure;
make;
sudo make install
You can’t perform that action at this time.