Skip to content

Instantly share code, notes, and snippets.

View FedorLap2006's full-sized avatar

Fedor Lapshin FedorLap2006

View GitHub Profile
@vv198x
vv198x / UNIX.c
Created March 13, 2023 13:26
Here is the famous line 2238
2230 /*
2231 * If the new process paused because it was
2232 * swapped out, set the stack level to the last call 3333 * to savu(u_ssav). This means that the return
2235 * actually returns from the last routine which did
2236 * the savu.
2237 *
2238 * You are not expected to understand this.
2239 */
2240 if(rp->p_flag&SSWAP) {
2241 rp->p_flag =& ~SSWAP;
@kkrypt0nn
kkrypt0nn / ansi-colors-discord.md
Last active April 30, 2025 03:01
A guide to ANSI on Discord

A guide to ANSI on Discord

Discord is now slowly rolling out the ability to send colored messages within code blocks. It uses the ANSI color codes, so if you've tried to print colored text in your terminal or console with Python or other languages then it will be easy for you.

Quick Explanation

To be able to send a colored text, you need to use the ansi language for your code block and provide a prefix of this format before writing your text:

\u001b[{format};{color}m
@rishavpandey43
rishavpandey43 / git-commit-styleguide.md
Last active May 7, 2025 02:34
This gist consist of the rules and best practice of good conventional git commit message

Git Commit Messages Style-Guides

  • Use the present tense ("Add feature" not "Added feature")
  • Use the imperative mood ("Move cursor to..." not "Moves cursor to...")
  • Limit the first line to 72 characters or less
  • Reference issues and pull requests liberally after the first line
  • When only changing documentation, include [ci skip] in the commit title
  • Consider starting the commit message with an applicable emoji

Types

@snakers4
snakers4 / process_wikipedia.py
Last active January 4, 2023 22:19
Post process wikipedia files produced by wikiextractor
import os
import re
import sys
import glob
import nltk
import gensim
import numpy as np
import pandas as pd
from tqdm import tqdm
from uuid import uuid4
@DasWolke
DasWolke / microservice bots.md
Last active May 4, 2025 15:53
Microservice bots

Microservice Bots

What they are and why you should use them

Introduction

Recently more and more chatbots appear, the overall chatbot market grows and the platform for it grows as well. Today we are taking a close look at what benefits creating a microservice chatbot on Discord - (a communication platform mainly targeted at gamers) would provide.

The concepts and ideas explained in this whitepaper are geared towards bots with a bigger userbase where the limits of a usual bot style appear with a greater effect

Information about Discord itself

(If you are already proficient with the Discord API and the way a normal bot works, you may skip ahead to The Concept)