Skip to content

Instantly share code, notes, and snippets.

View kadishmal's full-sized avatar
💭
Living in Present Landia...

Esen Sagynov kadishmal

💭
Living in Present Landia...
  • Mancho Devs
  • Bishkek, Kyrgyzstan
View GitHub Profile
@kadishmal
kadishmal / app.js
Created October 11, 2012 08:36
Simple Node.js server which responds in chunked transfer encoding
var http = require('http');
http.createServer(function (request, response) {
response.setHeader('Content-Type', 'text/html; charset=UTF-8');
response.setHeader('Transfer-Encoding', 'chunked');
var html =
'<!DOCTYPE html>' +
'<html lang="en">' +
'<head>' +
@kadishmal
kadishmal / delete_merged_git_branches.sh
Created May 14, 2014 05:29
A Bash script to delete already merged remote and local Git branches
#!/bin/bash
# Usage:
# chmod +x delete_merged_git_branches.sh
# ./delete_merged_git_branches.sh /path/to/git/repo
DIR="$1"
if [ -z "$DIR" ]; then
echo "Error: Git directory path should be provided."
echo "Usage:"
@kadishmal
kadishmal / gist:e03efafdd3996f5e6394
Created August 28, 2014 05:47
fd_count.sh: Watch open file descriptors count for a process.
#!/bin/sh
# Usage: sh fd_count.sh PID
RE='^[0-9]+$'
while :; do
clear;
for pid in `ps aux | awk '{print $2}'`; do
if [[ $pid =~ $RE ]] ; then
@kadishmal
kadishmal / match-bg-with-video-bg-color.tsx
Created February 3, 2021 06:34
Match page background with the background color of the video
/* External dependencies */
import React from 'react';
import { Col, Row, Text } from 'atomize';
/* Local dependencies */
import './under-construction.scss';
import videoSrc from '../../assets/video/under-construction.mp4';
export default class UnderConstruction extends React.PureComponent {
video: React.RefObject<HTMLVideoElement>;