Skip to content

Instantly share code, notes, and snippets.

View echo-Mike's full-sized avatar

Mikhail Demchenko echo-Mike

  • Align; Kaspersky
  • Novosibirsk, Russia
  • 17:07 (UTC +07:00)
View GitHub Profile
@MattPD
MattPD / cpp.std.coroutines.draft.md
Last active March 12, 2026 04:51
C++ links: Coroutines (WIP draft)
@treuherz
treuherz / build-essential.md
Last active December 16, 2019 21:20
Installing build-essential on WSL in Windows 10 1703

Due to a quirk in the case-sensitivity of WSL's filesytem, installations of the build-essential package (which contains C/C++ compilers and other things you'll need for installing Python, Bazel, etc) fail due to files "already existing". What's actually happening is that files with the same name but different casing already exist. I think this issue is fixed in newer versions of Windows, but for now you can circumvent the issue by leaving out the different-cased files. Obviously things will start going wrong if you try to compile something that relies on the different casing, but this solution should at least be workable for a while.

These commands will need to be run as a superuser

apt update
apt install build-essential  # will fail
dpkg \
  --path-exclude=/usr/include/linux/netfilter/xt_{TCPMSS,DSCP,CONNMARK,RATEEST,MARK}.h \
  --path-exclude=/usr/include/linux/netfilter_ipv6/ip6t_HL.h \
  --path-exclude=/usr/include/linux/netfilter_ipv4/ipt_{ECN,TTL}.h \
@eight04
eight04 / Obsidian.xml
Last active July 10, 2023 12:37
Notepad++ JSON lexer for obsidian theme
<LexerType name="json" desc="JSON" ext="">
<WordsStyle name="DEFAULT" styleID="0" fgColor="E0E2E4" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle name="NUMBER" styleID="1" fgColor="FFCD22" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle name="STRING" styleID="2" fgColor="EC7600" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle name="STRINGEOL" styleID="3" fgColor="808080" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle name="PROPERTYNAME" styleID="4" fgColor="678CB1" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle name="ESCAPESEQUENCE" styleID="5" fgColor="FF8409" bgColor="293134" fontName="" fontStyle="1" fontSize="" />
<WordsStyle name="LINECOMMENT" styleID="6" fgColor="008000" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle name="BLOCKCOMMENT" styleID="7" fgColor="008000" bgColor="293134" fontName="" fontStyle="0" fontSize="" />
<WordsStyle
@skochinsky
skochinsky / guids.txt
Created July 4, 2016 16:27
UEFI file/section GUIDs collection
; AMI
[GUID_FILE]
; ACPI tables
16D0A23E-C09C-407d-A14A-AD058FDD0CA1=ACPI
11D8AC35-FB8A-44d1-8D09-0B5606D321B9=DSDT
95DFCAE5-BB28-4d6b-B1E2-3AF3A6BF434F=PTID
FB045DB2-598E-485A-BA30-5D7B1B1BD54D=AOAC
60AC3A8F-4D66-4CD4-895A-C3F06E6665EE=iFfsAcpiTables
5B232086-350A-42c7-A70E-3497B5765D85=OEMSSDT
299141BB-211A-48a5-92C0-6F9A0A3A006E=PPMACPI
@fffaraz
fffaraz / dns.c
Created May 29, 2016 05:58
DNS Query Code in C with linux sockets
//DNS Query Program on Linux
//Author : Silver Moon (m00n.silv3r@gmail.com)
//Dated : 29/4/2009
//Header Files
#include<stdio.h> //printf
#include<string.h> //strlen
#include<stdlib.h> //malloc
#include<sys/socket.h> //you know what this is for
#include<arpa/inet.h> //inet_addr , inet_ntoa , ntohs etc
# This is the main configuration file for Bukkit.
# As you can see, there's actually not that much to configure without any plugins.
# For a reference for any variable inside this file, check out the Bukkit Wiki at
# http://wiki.bukkit.org/Bukkit.yml
#
# If you need help on this file, feel free to join us on irc or leave a message
# on the forums asking for advice.
#
# IRC: #spigot @ irc.spi.gt
# (If this means nothing to you, just go to http://www.spigotmc.org/pages/irc/ )
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
#
# /etc/screenrc
#
# This is the system wide screenrc.
#
# You can use this file to change the default behavior of screen system wide
# or copy it to ~/.screenrc and use it as a starting point for your own
# settings.
@abhisekp
abhisekp / Install Hubflow in Windows.md
Last active June 15, 2023 12:14
How to install hubflow in Windows?

How to install hubflow in Windows?

— by Abhisek Pattnaik <abhisekp@engineer.com>

Clone latest hubflow

git clone https://github.com/datasift/gitflow hubflow
cd hubflow

Copy all git-hf prefixed files to bin directory in git installation directory

@pavel-odintsov
pavel-odintsov / af_packet_classic.c
Last active May 28, 2025 11:21
af_packet_classic_habrahabr
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <iostream>
#include <unistd.h>
#include <boost/thread.hpp>
#include <arpa/inet.h>
#include <sys/socket.h>
@nhatminhle
nhatminhle / stdatomic.h
Last active February 25, 2025 15:23
A portable version of stdatomic.h extracted from the FreeBSD libc, for Clang 3.1+ and GCC 4.7+.
/*
* An implementation of C11 stdatomic.h directly borrowed from FreeBSD
* (original copyright follows), with minor modifications for
* portability to other systems. Works for recent Clang (that
* implement the feature c_atomic) and GCC 4.7+; includes
* compatibility for GCC below 4.7 but I wouldn't recommend it.
*
* Caveats and limitations:
* - Only the ``_Atomic parentheses'' notation is implemented, while
* the ``_Atomic space'' one is not.