View http.go
func Test(r *http.Request) http.Response {
err := r.Assure("param:numeric")
if err != nil{
return http.Error(400, err)
return http.Success()
View products.go
func Read(r *h.Request) h.Response{
return json(db.GetProducts())
View framework.go
// User Code
type User struct {
Id int
Name string
// implement auth interface
func (u User) Authenticate(r *http.Request) (interface{}, error) {
// auth
return u, nil
View MyEditor.js
var React = require('react');
var Editor = require('draft-js').Editor;
var EditorState = require('draft-js').EditorState;
var MyEditor = React.createClass({
getInitialState: function() {
return {editorState: EditorState.createEmpty()};
onChange: function(editorState) {
View .vimrc
let $GOPATH = 'home/marwan/go'
call plug#begin('~/.vim/plugged')
Plug 'fatih/vim-go'
call plug#end()
View readability.rb
#!/usr/bin/env ruby
# Author : Emad Elsaid (
# **Usage** :
# * `ruby readability.rb <accesstoken>`
# this will get a long term access token from the short term one
# you can create a facebook app and get access token from here
# * `ruby readability.rb`
# will start the script
require 'open-uri'
View gist:8a80863b6d07655880eb
directivesModule.directive('test', function(){
return {
// restrict: 'AEC',
templateUrl: '/public/partials/test.html',
write: function(){
controller: function($scope){
View index.html
<script type="text/javascript" src="/public/js/jquery-1.10.2.min.js"></script>
<script type="text/javascript" src="/public/lib/angular/angular.js"></script>
<script type="text/javascript" src="/public/lib/angular/angular-route.js"></script>
<script type="text/javascript" src="/public/lib/angular/angular-resource.min.js"></script>
<script type="text/javascript" src="/public/lib/angular/angular-cookies.min.js"></script>
<script type="text/javascript" src="/public/js/app.js"></script>
<script type="text/javascript" src="/public/js/services.js"></script>
<script type="text/javascript" src="/public/js/controllers.js"></script>
<script type="text/javascript" src="/public/js/controllers/signup.js"></script>
<script type="text/javascript" src="/public/js/controllers/login.js"></script>
View pqarray
type User struct {
Id int64
Name string
Email string
Username string
TablesIds []uint8
HashedPassword []byte
Created int64
Updated int64