Skip to content

Instantly share code, notes, and snippets.

View refactormyself's full-sized avatar

Saheed O. Bolarinwa refactormyself

View GitHub Profile
@refactormyself
refactormyself / introrx.md
Created April 28, 2016 04:00 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
<div class="message status">
Sass 3.3 envoie du poney !
</div>
<div class="message warning">
Une fois tombé dans Sass,
il est difficile de revenir en arrière !
</div>
<div class="message error">
LESS c'est senSass :]
</div>

History Data Structures

For stateful applications, there are 5 different ways of managing the history of state:

  • No History - Living in the moment. - Examples: Any stateful application that doesn't discards all previous states upon mutation.
  • Ad Hoc Snapshotting - Allows restoration to manually saved snapshots. - Examples: Memento Pattern.
  • Singleton - Only remembers the previous snapshot, where undoing the undo is just another undo. - Examples: Xerox PARC Bravo.
  • 1 Stack - Allows linear undo. - Examples: AtariWriter.
  • 2 Stack - Allows linear undo and redo. - Examples: Browser History, Microsoft Word, Adobe Photoshop.
@refactormyself
refactormyself / clean-up-boot-partition-ubuntu.md
Created April 20, 2020 06:40 — forked from ipbastola/clean-up-boot-partition-ubuntu.md
Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Reference

Case I: if /boot is not 100% full and apt is working

1. Check the current kernel version

$ uname -r 
@refactormyself
refactormyself / Freenode Registration Help.md
Created April 28, 2020 13:35
Here'e an example of how to register a nickname on Freenode IRC.

Here'e an example of how to register a nick on Freenode IRC. It's a little tricky, but if you follow some simple steps, you'll get through it okay. All you need to do is connect to the Freenode IRC network and have a little talk with NickServ.

The first and most confusing questions can be combined:

  1. How do I know if my nick is already registered to someone else?
  2. How do I talk to NickServ?

Start by connecting your client to irc.freenode.net and joining any chat.

Next, type this command in the chat window:

@refactormyself
refactormyself / irc.md
Created April 28, 2020 14:18 — forked from xero/irc.md
irc cheat sheet

#IRC Reference

Not intended as a guide for newbies, more like a "cheat sheet" for the somewhat experienced IRC user, especially one who wields some power over a channel.

##The Basics

  • /join #channel
    • Joins the specified channel.
  • /part #channel
    • Leaves the specified channel.
@refactormyself
refactormyself / how-to-install-latest-gcc-on-ubuntu-lts.txt
Created May 13, 2020 13:06 — forked from application2000/how-to-install-latest-gcc-on-ubuntu-lts.txt
How to install latest gcc on Ubuntu LTS (12.04, 14.04, 16.04)
These commands are based on a askubuntu answer http://askubuntu.com/a/581497
To install gcc-6 (gcc-6.1.1), I had to do more stuff as shown below.
USE THOSE COMMANDS AT YOUR OWN RISK. I SHALL NOT BE RESPONSIBLE FOR ANYTHING.
ABSOLUTELY NO WARRANTY.
If you are still reading let's carry on with the code.
sudo apt-get update && \
sudo apt-get install build-essential software-properties-common -y && \
sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y && \
@refactormyself
refactormyself / byobuCommands
Created May 3, 2021 00:37 — forked from jshaw/byobuCommands
Byobu Commands
Byobu Commands
==============
byobu Screen manager
Level 0 Commands (Quick Start)
------------------------------
<F2> Create a new window
KEYBINDINGS
byobu keybindings can be user defined in /usr/share/byobu/keybindings/ (or within .screenrc if byobu-export was used). The common key bindings
are:
F2 - Create a new window
F3 - Move to previous window
F4 - Move to next window
Byobu is a suite of enhancements to tmux, as a command line
tool providing live system status, dynamic window management,
and some convenient keybindings:
F1 * Used by X11 *
Shift-F1 Display this help
F2 Create a new window
Shift-F2 Create a horizontal split
Ctrl-F2 Create a vertical split
Ctrl-Shift-F2 Create a new session