Skip to content

Instantly share code, notes, and snippets.

View cansurmeli's full-sized avatar

Can Sürmeli cansurmeli

View GitHub Profile
@cansurmeli
cansurmeli / awesome-shell.sh
Created November 18, 2021 08:44 — forked from toonevdb/awesome-shell.sh
Use this script to install zsh, zprezto, enhancd and more to create a awesome shell (tested on Debian and Ubuntu server)
#
# >> Generate awesome shellness with zsh ^_^ <<
#
# @author toonevdb <[email protected]>
#
#
apt-get update
apt-get install -y zsh curl git locales gawk percol fzf
chsh -s "$(which zsh)"
@cansurmeli
cansurmeli / cuda_check.py
Created August 17, 2021 07:11 — forked from f0k/cuda_check.py
Simple python script to obtain CUDA device information
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Outputs some information on CUDA-enabled devices on your computer,
including current memory usage.
It's a port of https://gist.github.com/f0k/0d6431e3faa60bffc788f8b4daa029b1
from C to Python with ctypes, so it can run without compiling anything. Note
that this is a direct translation with no attempt to make the code Pythonic.
//
// SimpleScrollingStack.swift
// A super-simple demo of a scrolling UIStackView in iOS 9
//
// Created by Paul Hudson on 10/06/2015.
// Learn Swift at www.hackingwithswift.com
// @twostraws
//
import UIKit
@cansurmeli
cansurmeli / iOS Support Matrix Text (english)
Last active May 28, 2017 06:55 — forked from rjstelling/iOS Support Matrix Text (english)
This is the text that needs translating so we can release localised versions of the iOS Support Matrix. Feel free to fork and translate: http://www.empiricalmagic.com/post/34832825209/ios-support-matrix-v2-0-winter-2012
iOS Destek Çizelgesi
Kış 2012 Sürümü - v2.0
iPhone Haziran 2007
iPod touch Eylül 2007, Şubat 2008 (32GB only)
iPhone 3G Temmuz 2008
iPod touch (2nd Nesil) Eylül 2008 Eylül 2009 - (8GB only)
iPhone 3GS Haziran 2009
iPod touch (3rd Nesil) Eylül 2009
iPad Nisan 2010
iPhone 4 Haziran 2010
@cansurmeli
cansurmeli / CamelCaseToTitleCase.swift
Created June 12, 2016 08:54
Convert camelCase to titleCase with Swift via functional programming
let camelCaseString = "noRealTimeLocationData"
let stringCharacters = String(camelCaseString).characters.map{ String($0) }
let titleCaseString = stringCharacters.flatMap{ $0.lowercaseString != $0 ? " " + $0 : $0 }.joinWithSeparator("")
print(titleCaseString)