Skip to content

Instantly share code, notes, and snippets.

View afiskon's full-sized avatar

Aleksander Alekseev afiskon

View GitHub Profile
@jjcarrier
jjcarrier / FPGA_2_LCD.v
Created December 28, 2011 18:40
A simple character LCD controller core written in Verilog
`timescale 1ns / 1ps
//////////////////////////////////////////////////////////////////////////////////
// Company: Carrier Frequency, Inc.
// Engineer: Jon Carrier
//
// Create Date: 21:33:11 06/17/2011
// Design Name:
// Module Name: FPGA_2_LCD
// Project Name:
// Target Devices:
@kyleturner
kyleturner / Remove Submodule
Created January 5, 2012 01:07
How to remove a submodule from a Github project
To remove a submodule you need to:
Delete the relevant line from the .gitmodules file.
Delete the relevant section from .git/config.
Run git rm --cached path_to_submodule (no trailing slash).
Commit and delete the now untracked submodule files.
@maxlapshin
maxlapshin / small_erlang.sh
Last active December 17, 2015 00:09
Build and clean small server erlang distribution without useless libraries
#!/bin/bash
[ -f /usr/bin/gcc ] || (apt-get update && apt-get install -y build-essential libncurses-dev libssl-dev chrpath)
#wget http://www.hpl.hp.com/research/linux/atomic_ops/download/libatomic_ops-7.2d.tar.gz
#tar zxf libatomic_ops-7.2d.tar.gz
#cd libatomic_ops-7.2/
#./configure --prefix=/opt/flussonic
#make install
#cd ..
@LeSpocky
LeSpocky / rounded_corner.scad
Last active March 4, 2024 21:50
rounded square in openscad
module rounded_square( width, radius_corner ) {
translate( [ radius_corner, radius_corner, 0 ] )
minkowski() {
square( width - 2 * radius_corner );
circle( radius_corner );
}
}
module alternative_square( width, r_c ) {
hull() {
@lelandbatey
lelandbatey / whiteboardCleaner.md
Last active June 2, 2024 11:23
Whiteboard Picture Cleaner - Shell one-liner/script to clean up and beautify photos of whiteboards!

Description

This simple script will take a picture of a whiteboard and use parts of the ImageMagick library with sane defaults to clean it up tremendously.

The script is here:

#!/bin/bash
convert "$1" -morphology Convolve DoG:15,100,0 -negate -normalize -blur 0x1 -channel RBG -level 60%,91%,0.1 "$2"

Results

@ocmanv
ocmanv / cabal
Created February 24, 2014 10:06
cabal command line completion
# cabal command line completion
# Copyright 2014 "Osman Veliev" <ocmanv@gmail.com>
#
# Реализовано:
# - кеширование списка пакетов - _cabal_cach()
# - автодополнение версии пакета
# - напоминания об устаревшей базе пакетов - _cabal_log()
# - и установленных версиях пакета - _cabal_installed()
# - автодополнение для "cabal list"
@miguelmota
miguelmota / README.md
Last active May 25, 2024 13:23
Multiple accounts with Mutt E-Mail Client (gmail example)

How to set up multiple accounts with Mutt E-mail Client

Thanks to this article by Christoph Berg

Instructions

Directories and files

~/
@ringerc
ringerc / schema.sql
Created February 8, 2016 14:34
Demo Python script for replicating to Solr
CREATE TABLE book_lines
(
id serial primary key,
book_line text not null
);
@densh
densh / Snake.scala
Last active December 19, 2021 05:05
Snake game in 200 lines of Scala Native and SDL2 as demoed during Scala Matsuri 2017
import scalanative.native._
import SDL._
import SDLExtra._
@extern
@link("SDL2")
object SDL {
type Window = CStruct0
type Renderer = CStruct0