In Git you can add a submodule to a repository. This is basically a sub-repository embedded in your main repository. This can be very useful. A couple of usecases of submodules:
- Separate big codebases into multiple repositories.
| #include <iostream> | |
| #include "console.hpp" | |
| void Console::run() | |
| { | |
| std::cout << "First message" << std::endl; | |
| std::cout << "> " << std::flush; | |
| connect(m_notifier, SIGNAL(activated(int)), this, SLOT(readCommand())); | |
| } |
| /* | |
| Check SSE/AVX support. | |
| This application can detect the instruction support of | |
| SSE, SSE2, SSE3, SSSE3, SSE4.1, SSE4.2, SSE4a, SSE5, and AVX. | |
| */ | |
| #include <iostream> | |
| #ifdef _MSC_VER | |
| #include <intrin.h> | |
| #endif |
| /* | |
| Put this in ~/.config/sublime-text-3/Packages/User | |
| */ | |
| { | |
| "name": "briandfoy", | |
| "author": "brian d foy <[email protected]>", | |
| "variables": | |
| { | |
| "black": "hsl(0,0%,0%)", |
Sometimes a programming language has a "strict mode" to restrict unsafe constructs. E.g., Perl has use strict, Javascript has "use strict", and Visual Basic has Option Strict. But what about bash? Well, bash doesn't have a strict mode as such, but it does have an unofficial strict mode:
set -euo pipefail
set -e
On September 28, 2021, I asked on Twitter:
PL Twitter:
you get to recommend one published PL paper for an undergrad to read with oversight by someone experienced. the paper should be interesting, approachable, and (mostly) self-contained.
what paper do you recommend?
| #lang racket/base | |
| (require quickscript | |
| racket/list | |
| racket/class | |
| framework | |
| racket/gui/base) | |
| ;;; Author: Laurent Orseau https://github.com/Metaxal | |
| ;;; License: [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0) or |