Skip to content

Instantly share code, notes, and snippets.

@belak
belak / .gitignore
Last active July 6, 2022 19:26
Simple Emacs Starter Kit
README.el
backups/
elpa/
projectile-bookmarks.eld
recentf
smex-items
@zarzen
zarzen / spacemacs-cpp.md
Last active January 23, 2024 13:06
C++ development environment setup in Spacemacs
@d2s
d2s / installing-node-with-nvm.md
Last active April 24, 2025 18:50
Installing Node.js to Linux & macOS & WSL with nvm

Installing Node.js with nvm to Linux & macOS & WSL

A quick guide on how to setup Node.js development environment.

Install nvm for managing Node.js versions

nvm allows installing several versions of Node.js to the same system. Sometimes applications require a certain versions of Node.js to work. Having the flexibility of using specific versions can help.

  1. Open new Terminal window.
@bkaradzic
bkaradzic / orthodoxc++.md
Last active April 25, 2025 00:16
Orthodox C++

Orthodox C++

What is Orthodox C++?

Orthodox C++ (sometimes referred as C+) is minimal subset of C++ that improves C, but avoids all unnecessary things from so called Modern C++. It's exactly opposite of what Modern C++ suppose to be.

Why not Modern C++?

This is unmaintained, please visit Ben-PH/spacemacs-cheatsheet

Useful Spacemacs commands

  • SPC q q - quit
  • SPC w / - split window vertically
  • SPC w - - split window horizontally
  • SPC 1 - switch to window 1
  • SPC 2 - switch to window 2
  • SPC w c - delete current window
wget http://repos.rcn-ee.net/debian/pool/main/r/rcn-ee-archive-keyring/rcn-ee-archive-keyring_2015.10.22~bpo70+20151022+1_all.deb
sudo dpkg -i rcn-ee-archive-keyring_2015.10.22~bpo70+20151022+1_all.deb
sudo sh -c "echo deb http://ftp.us.debian.org/debian stretch main >> /etc/apt/sources.list"
sudo apt-get update
sudo apt-get install -y libczmq-dev python-zmq libjansson-dev libwebsockets-dev libxenomai-dev lsb-release cython bwidget
sudo apt-get install -y --no-install-recommends devscripts equivs
sudo apt-get install -y \
libgnomeprintui2.2 \
python-configobj \
python-glade2 \
@davoclavo
davoclavo / spacemacs-cheatsheet.md
Last active October 26, 2024 19:46 — forked from 526avijitgupta/spacemacs-cheatsheet.md
Spacemacs cheatsheet

emacs --daemon to run in the background. emacsclient.emacs24 <filename/dirname> to open in terminal

NOTE: "M-m and SPC can be used interchangeably".

  • Undo - C-/
  • Redo - C-?
  • Change case: 1. Camel Case : M-c 2. Upper Case : M-u
  1. Lower Case : M-l
@Luthaf
Luthaf / Foo.cpp
Last active January 6, 2025 17:17
Calling C++ from Fortran
#include "Foo.hpp"
#include <iostream>
using namespace std;
Foo::Foo(int _a, int _b): a(_a), b(_b){
cout << "C++ side, constructor" << endl;
}
Foo::~Foo(){
@dcarrith
dcarrith / src.Makefile.patch
Created February 27, 2015 19:47
fPIC Patch file for src/Makefile for lua-5.3.0
--- src/Makefile.original2015-02-27 10:53:53.130125907 -0500
+++ src/Makefile 2015-02-27 10:53:24.674126798 -0500
@@ -7,7 +7,7 @@
PLAT= none
CC= gcc -std=gnu99
-CFLAGS= -O2 -Wall -Wextra -DLUA_COMPAT_5_2 $(SYSCFLAGS) $(MYCFLAGS)
+CFLAGS= -O2 -Wall -Wextra -DLUA_COMPAT_5_2 $(SYSCFLAGS) $(MYCFLAGS) -fPIC
LDFLAGS= $(SYSLDFLAGS) $(MYLDFLAGS)
LIBS= -lm $(SYSLIBS) $(MYLIBS)
if (NOT INSTALLING)
set (WORKING DIRECTORY "${CMAKECURRENTBINARYDIR}/Install")
file (MAKEDIRECTORY "${DIRECTORY}")
executeprocess (COMMAND "${CMAKECOMMAND}"
-DINSTALLING=TRUE
-DINSTALLPREFIX=${MYINSTALLPREFIX} "${CMAKECURRENTSOURCEDIR}"
WORKING_DIRECTORY "${DIRECTORY}"
)
executeprocess (COMMAND "${CMAKECOMMAND}"
--build .