Skip to content

Instantly share code, notes, and snippets.

View yuceltoluyag's full-sized avatar
💭
I may be slow to respond.

yücel yuceltoluyag

💭
I may be slow to respond.
View GitHub Profile
@RobbiNespu
RobbiNespu / blogspot_to_jekyll.rb
Last active July 19, 2021 11:24 — forked from danielgomezrico/blogspot_to_jekyll.rb
update feedjira fetch_and_parse method
#!/usr/bin/env ruby
#
# Convert blogger (blogspot) posts to jekyll posts
#
# Basic Usage
# -----------
#
# ./blogger_to_jekyll.rb feed_url
#
# where `feed_url` can have the following format:
@ecosse3
ecosse3 / update-neovim-nightly.sh
Last active December 21, 2023 19:02
Update Neovim Nightly from latest github release
#!/bin/bash
# Colors definitions
RED='\033[0;31m'
GREEN='\033[0;32m'
NC='\033[0m' # No Color
BOLD=$(tput bold)
NORMAL=$(tput sgr0)
# Check if necessary applications are installed
@mutcianm
mutcianm / set-interface
Last active April 21, 2021 22:58
Simple bash script to globally toggle dark/light look and feel
#!/bin/bash
if [[ $1 == "dark" ]]; then
UI_THEME_GTK="Mojave-dark"
UI_THEME_QT="KvMojave"
UI_ICONS="Faenza-Ambiance"
VIM_BG="dark"
elif [[ $1 == "light" ]]; then
UI_THEME_GTK="Mojave-light"
UI_THEME_QT="KvMojaveLight"
@unique1984
unique1984 / composer-completion
Last active January 4, 2021 19:00
Composer bash_completion
_composer()
{
local cur=${COMP_WORDS[COMP_CWORD]}
local cmd=${COMP_WORDS[0]}
if ($cmd > /dev/null 2>&1)
then
COMPREPLY=( $(compgen -W "$($cmd list | awk '$0 ~ /^ .*/' | awk {'print $1'} | grep -io '[^/_,]*' | grep -v 'command')" -- $cur) )
fi
}
complete -F _composer composer
@ademalp
ademalp / seo_helper.php
Created July 17, 2019 07:22
Codeigniter SEO Link
<?php
function seo_link($title)
{
$title = str_replace(array('I', 'İ'), 'i', $title);
$title = iconv('UTF-8', 'ASCII//TRANSLIT//IGNORE', $title);
return url_title($title, '-', true);
}
$title = "Türkçe karakter içeren link IĞÜŞİÖÇ";
<?php
function image_thumb($file, $width = 460, $height = 0, $save = true, $quality = 80)
{
$qual = round(9 - ($quality / (100 / 9)));
//log_message('debug',"Kalite: $quality $qual");
$i = $file;
$x = $width;
$y = $height;
@laravel-shift
laravel-shift / .php-cs-fixer.php
Last active April 9, 2024 14:08
PHP CS Fixer - Laravel Coding Style Ruleset
<?php
use PhpCsFixer\Config;
use PhpCsFixer\Finder;
$rules = [
'array_indentation' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => [
'default' => 'single_space',
@vicgonvt
vicgonvt / deployment_guide.md
Last active March 17, 2024 06:51
Deployment Guide for Ubuntu Server from Scratch with Laravel
@j1mc
j1mc / bulma-sass-scss.rb
Last active August 14, 2023 05:04 — forked from DanyHenriquez/bulma-sass-scss.rb
Convert bulma from sass to scss
#!/usr/bin/env ruby
require 'tmpdir'
require 'fileutils'
dir = Dir.tmpdir()
if File.directory?("#{dir}/bulma")
FileUtils.remove_dir("#{dir}/bulma")
end
@rmckeel
rmckeel / gulp-spawn.js
Last active August 9, 2021 23:37
Gulp no-dependency spawn / execute a file with live stdout feedback
const gulp = require( 'gulp' );
const spawn = require( 'child_process' ).spawn;
/**
* This solution to execute and watch a shell function from Gulp is
* adapted from https://stackoverflow.com/a/10232330/3232832
*
* e.g. callSpawn( 'ping', [ '-c 5', 'google.com' ], cb );
*/
function callSpawn( command, arguments, cb ) {