Skip to content

Instantly share code, notes, and snippets.

View mertkahyaoglu's full-sized avatar
👾

Mert Kahyaoğlu mertkahyaoglu

👾
View GitHub Profile
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
display: inline-block;
width: 100%;
// accessToken
https://api.instagram.com/oauth/authorize/?client_id=[clientID]&redirect_uri=[redirectURI]&response_type=token
// userid
https://api.instagram.com/v1/users/self/?access_token=412025777.b432d9c.98d4c8dc5f824153b840dd281533d393
https://api.instagram.com/v1/users/self/media/recent/?access_token=412025777.b432d9c.98d4c8dc5f824153b840dd281533d393
import os
from PIL import Image
from psd_tools import PSDImage
tifpath = "tif"
psdpath = "psd"
if not os.path.exists(tifpath):
os.makedirs(tifpath)
if not os.path.exists(psdpath):
os.makedirs(psdpath)
import os
from PIL import Image
yourpath = os.getcwd()
for root, dirs, files in os.walk(yourpath, topdown=False):
for name in files:
print(os.path.join(root, name))
if os.path.splitext(os.path.join(root, name))[1].lower() == ".tif":
outpath = os.path.splitext(os.path.join("dist", name))[0] + ".png"
if os.path.isfile(outpath):
var updates = []update{
{[]string{"a", "y"}, []int{8, 0}},
{[]string{"n"}, []int{8}},
{[]string{"k", "j", "g", "z"}, []int{1, 9, 3, 3}},
{[]string{"o", "j"}, []int{7, 7}},
{[]string{"w", "a", "d"}, []int{6, 9, 0}},
{[]string{"x", "l"}, []int{4, 2}},
{[]string{"p", "f", "g"}, []int{7, 6, 0}},
{[]string{"d", "j", "q", "o", "a"}, []int{9, 1, 0, 0, 9}},
{[]string{"x", "o", "u", "p", "s"}, []int{0, 4, 9, 0, 6}},
-webkit-font-smoothing: antialiased;
text-rendering: optimizeLegibility;
@mertkahyaoglu
mertkahyaoglu / card.css
Created December 31, 2016 08:05
Awesome Card CSS
.card {
padding: 10px;
display: block;
background: white;
border-radius: 6px;
box-shadow: 0px 2px 8px 2px rgba(0, 0, 0, 0.08);
margin-bottom: 30px;
}
@mertkahyaoglu
mertkahyaoglu / routine.go
Created December 21, 2016 21:12
Go routine example
package main
import (
"fmt"
"time"
)
func count(id int) {
for i := 0; i < 10; i++ {
@mertkahyaoglu
mertkahyaoglu / readme.md
Last active August 24, 2016 22:15
Jekyll Admin Initial Release
layout title date author categories
news_item
Jekyll Admin Initial Release
2016-08-23 13:21:02 -0700
mertkahyaoglu
community

Jekyll's Google Summer of Code Project has come to its end. The anticipated admin panel for Jekyll finally made its first release. After a hard work of three months with my dear mentors @benbalter, @jldec and @parkr, I'm proud to announce that we are releasing Jekyll Admin.

require 'json'
require 'yaml'
require 'pathname'
# Jekyll plugin that auto-generates the `db.json` of a Jekyll project
module JekyllExport
class Generator < Jekyll::Generator
def generate(site)
File.open("db.json", "w") do |f|