Skip to content

Instantly share code, notes, and snippets.

View muratsplat's full-sized avatar

Anonymous muratsplat

  • USA
View GitHub Profile
@muratsplat
muratsplat / Example Repository Abstract Clas.php
Last active August 29, 2015 14:15
A abstract class for repository
<?php namespace Boruu\Root\Mvc\Repository;
/**
* Core Repository for Eloquent
*
* @author Murat Ödünç <murat.asya@gmail.com>
* @copyright (c) 2015, Murat Ödünç
* @license http://www.gnu.org/licenses/gpl-3.0.html GPLv3
* @package Repository
@muratsplat
muratsplat / httpPrefix.js
Last active August 29, 2015 14:15
HttpPrefix Directive with test For Angular, This directive make force user to entry 'http://' on input element
'use strict';
/**
* @ngdoc directive
* @name boruu.directive:httpPrefix
* @description
* # httpPrefix
*/
angular.module('yourApp')
.directive('httpPrefix', function () {
@muratsplat
muratsplat / front.blade.php
Created June 13, 2015 06:01
An Example Layout of Blade Template for Laravel
<!doctype html>
<html lang="{{Session::get('lang')}}" class="no-js">
{{-- HEAD --}}
@include('Muratsplat\mvc\view\front::_head')
{{-- END OF HEAD --}}
<body class="@yield('cssOnBody')">
<!-- background wrapper -->
<div id="container">
{{-- HEADER TOP MENU --}}
@include('Muratsplat\mvc\view\front::_header_top_menu')
@muratsplat
muratsplat / SearchController.php
Created July 8, 2015 14:25
SearchController on Laravel Apps
<?php
namespace Muratsplat\mvc\controller\front;
use Illuminate\Http\Request;
use Illuminate\Database\Eloquent\Collection;
use Muratsplat\Multilang\Interfaces\LangInterface;
use Muratsplat\Multilang\Interfaces\MainInterface;
use Muratsplat\mvc\model\Page\Page;
use Muratsplat\mvc\model\Page\PageLang;
@muratsplat
muratsplat / FileRepository.php
Created July 13, 2015 18:34
FileBindingOnModel Repository Class For Laravel
<?php namespace Muratsplat\Repository;
use Muratsplat\Repository\IFileRepository;
use Illuminate\Database\DatabaseManager;
use Illuminate\Support\Collection;
use Illuminate\Cache\Repository as Cache;
use Illuminate\Config\Repository as Config;
use Illuminate\Events\Dispatcher;
use RuntimeException;
@muratsplat
muratsplat / babelAngularExtention.js
Last active August 30, 2015 21:04
Full support Angular + Babel + Modules + Uglify + Avoid issues of the Dependency Injection by helping ng-Annotate
//babelAngularExtention.js
var gulp = require('gulp');
var Elixir = require('laravel-elixir');
/**
* These for Angular + Babel + Uglify + Avoid issues of the Dependency Injection
*/
var sourcemaps = require('gulp-sourcemaps');
var babel = require('gulp-babel');;
@muratsplat
muratsplat / app.yml
Last active October 14, 2015 13:39
Example of app.yml for Laravel5.x + Elixir on Google App Engine
application: yourApp
version: one
runtime: php55
api_version: 1
handlers:
- url: /favicon\.ico
static_files: public/favicon.ico
upload: public/favicon\.ico
@muratsplat
muratsplat / post.go
Created February 25, 2016 21:12
Simple Web Server written in Golang
package main
import (
"fmt"
"log"
"net/http"
"strings"
"time"
)
@muratsplat
muratsplat / bach_prompt.sh
Last active July 20, 2016 15:41
Bash Git Prompt Patch for Git 2.9.2
# @gf3’s Sexy Bash Prompt, inspired by “Extravagant Zsh Prompt”
# Shamelessly copied from https://github.com/gf3/dotfiles
# Screenshot: http://i.imgur.com/s0Blh.png
if [[ $COLORTERM = gnome-* && $TERM = xterm ]] && infocmp gnome-256color >/dev/null 2>&1; then
export TERM=gnome-256color
elif infocmp xterm-256color >/dev/null 2>&1; then
export TERM=xterm-256color
fi