Skip to content

Instantly share code, notes, and snippets.

View mesuutt's full-sized avatar

Mesut Taşçı mesuutt

View GitHub Profile
@huytd
huytd / wordle.md
Last active March 17, 2024 20:51
Wordle in less than 50 lines of Bash

image

How to use:

./wordle.sh

Or try the unlimit mode:

@yogthos
yogthos / clojure-beginner.md
Last active April 15, 2024 17:11
Clojure beginner resources

Introductory resources

@chriscandy
chriscandy / install-arch-linux-using-efi-and-grub.md
Last active March 31, 2024 21:12
Install Arch Linux using EFI and GRUB

Installing Arch linux with EFI

  1. Change keyboard layout:

    • loadkeys no
  2. Verify boot mode:

    • ls /sys/firmware/efi/efivars (If the directory exist your computer supports EFI)
  3. Ping some site on the Internet to verify connection:

  • ping archlinux.org
@collinjackson
collinjackson / nested_scroll_view.dart
Last active September 25, 2022 05:29
nestedscrollview example
// Copyright 2017, the Flutter project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
import 'package:flutter/material.dart';
void main() {
runApp(new TestApp());
}
@arsham
arsham / go_cpu_memory_profiling_benchmarks.sh
Last active November 20, 2023 03:42
Go cpu and memory profiling benchmarks. #golang #benchmark
go test -run=. -bench=. -benchtime=5s -count 5 -benchmem -cpuprofile=cpu.out -memprofile=mem.out -trace=trace.out ./package | tee bench.txt
go tool pprof -http :8080 cpu.out
go tool pprof -http :8081 mem.out
go tool trace trace.out
go tool pprof $FILENAME.test cpu.out
# (pprof) list <func name>
# go get -u golang.org/x/perf/cmd/benchstat
benchstat bench.txt
@mgwidmann
mgwidmann / twitter_stream.ex
Last active November 29, 2022 20:35
Infinite Streams with Elixir
# Elixir has lazily evaluated enumerable objects that allow you
# to work with enumerable objects like lists either only as needed
# or infinitely.
# Start up iex to play around
$ iex
# Typical enumeration is done eagerly where the result is computed ASAP
iex> Enum.map(1..10, fn i -> i * 2 end)
[2, 4, 6, 8, 10, 12, 14, 16, 18, 20]
@staltz
staltz / introrx.md
Last active April 15, 2024 10:24
The introduction to Reactive Programming you've been missing
@cdiener
cdiener / asciinator.py
Last active January 5, 2023 17:24
Convert image to ascii art
import sys; from PIL import Image; import numpy as np
chars = np.asarray(list(' .,:;irsXA253hMHGS#9B&@'))
if len(sys.argv) != 4: print( 'Usage: ./asciinator.py image scale factor' ); sys.exit()
f, SC, GCF, WCF = sys.argv[1], float(sys.argv[2]), float(sys.argv[3]), 7/4
img = Image.open(f)
S = ( round(img.size[0]*SC*WCF), round(img.size[1]*SC) )
img = np.sum( np.asarray( img.resize(S) ), axis=2)
@takeshixx
takeshixx / hb-test.py
Last active March 9, 2024 13:37
OpenSSL heartbeat PoC with STARTTLS support.
#!/usr/bin/env python2
"""
Author: takeshix <takeshix@adversec.com>
PoC code for CVE-2014-0160. Original PoC by Jared Stafford (jspenguin@jspenguin.org).
Supportes all versions of TLS and has STARTTLS support for SMTP,POP3,IMAP,FTP and XMPP.
"""
import sys,struct,socket
from argparse import ArgumentParser
@v0lkan
v0lkan / ozgurluk.md
Last active December 25, 2023 12:27
Ozgur Kaynak Projelerine Nasil Katkida Bulunabilirim

Ozgur Kaynak Projelerine Nasil Katkida Bulunabilirim

Ozgur kaynakli projelere destek olmak, bir yazilimcinin kendini gelistirmesi, kariyerinde ilerlemesi, ve daha da onemlisi baskalarina yardimci olabilmeleri ve topluluga katki saglamalari acisindan gercekten cok onemli.

Girecegin is mulakatlarinin hatri sayilir bir oraninda ozgur kaynakli kodlarin, yan projelerin, ve is disinda kendini gelistirmek icin neler yaptigin hakkinda konusuyor olacaksin – En azindan Silikon Vadisi'nde durum boyle.

Yeni teknolojiler ogrenmekten, daha once tanimadigin onlarca insanla iletisim kurmak; kendini ve yazdigin kodu tum dunyanin gozleri onune sermek biraz urkutucu olabilse de, sana cok sey katacaktir.

Bu dokumanda konuyla ilgili aklima gelenleri paylasiyorum. Eminim gozumden kacan seyler olacak. Eklemek istediklerini, gorus, dusunce, onerileri, ve yorumlarini ekle.