mirror of
https://github.com/balkian/balkian.github.com.git
synced 2025-08-24 20:52:19 +00:00
Move to Hugo
This commit is contained in:
21
content/cheatsheet/emacs.md
Normal file
21
content/cheatsheet/emacs.md
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
title: Emacs
|
||||
description: Configuration files and tricks for emacs
|
||||
tags:
|
||||
- emacs
|
||||
- org
|
||||
- productivity
|
||||
- lisp
|
||||
|
||||
---
|
||||
|
||||
|
||||
# Show plain text version
|
||||
|
||||
<!--more-->
|
||||
|
||||
```lisp
|
||||
(font-lock-mode)
|
||||
```
|
||||
|
||||
|
70
content/cheatsheet/linux.md
Normal file
70
content/cheatsheet/linux.md
Normal file
@@ -0,0 +1,70 @@
|
||||
---
|
||||
title: Linux
|
||||
author: "Unknown Author"
|
||||
description: Tips and tricks for GNU/Linux and Unix
|
||||
tags:
|
||||
- linux
|
||||
- arch
|
||||
|
||||
---
|
||||
|
||||
# Black screen and LightDM doesn't unlock
|
||||
|
||||
Add this to your /etc/lightdm/lightdm.conf file:
|
||||
|
||||
```
|
||||
[LightDM]
|
||||
logind-check-graphical=true
|
||||
```
|
||||
|
||||
|
||||
# Edit previous commands
|
||||
|
||||
`fc` is a shell builtin to list and edit previous commands in an editor.
|
||||
In addition to editing a single line (which you can also do with `C-x C-e`), it also allows you to edit and run several lines at the same time.
|
||||
You use it like this:
|
||||
|
||||
List previous commands
|
||||
```
|
||||
$ fc -l
|
||||
10259 nvim deploy.sh
|
||||
10260* cd ..
|
||||
10261* nvim content/cheatsheet/linux.md
|
||||
10262 cd
|
||||
```
|
||||
|
||||
List commands with date (in zsh)
|
||||
|
||||
```
|
||||
$ fc -ld
|
||||
10260* 19:38 cd ..
|
||||
10261* 19:38 nvim content/cheatsheet/linux.md
|
||||
10262 19:40 cd
|
||||
10263 19:40 fc -l
|
||||
```
|
||||
|
||||
You can add the date too:
|
||||
|
||||
```
|
||||
$ fc -fld
|
||||
10262 1/10/2019 19:40 cd
|
||||
10263 1/10/2019 19:40 fc -l
|
||||
10264 1/10/2019 19:40 fc -ld
|
||||
```
|
||||
|
||||
You can edit a range of commands
|
||||
|
||||
```
|
||||
$ fc 10262 10264
|
||||
```
|
||||
|
||||
|
||||
The range can be relative to the current position, so the previous command is equivalent to:
|
||||
|
||||
```
|
||||
$ fc -3 -1
|
||||
```
|
||||
|
||||
If you save and exit, all commands are executed as a script, and it will be added to your history.
|
||||
|
||||
Source: https://shapeshed.com/unix-fc/
|
21
content/cheatsheet/python.md
Normal file
21
content/cheatsheet/python.md
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
title: Python
|
||||
description: Tips and useful libraries for python developers
|
||||
tags:
|
||||
- python
|
||||
- programming
|
||||
---
|
||||
|
||||
# Interesting libraries
|
||||
|
||||
## [TQDM](https://github.com/tqdm/tqdm)
|
||||
|
||||
|
||||
From tqdm's github repository:
|
||||
|
||||
> tqdm means "progress" in Arabic (taqadum, تقدّم) and an abbreviation for "I love you so much" in Spanish (te quiero demasiado).
|
||||
|
||||
|
||||

|
||||
|
||||
#
|
19
content/cheatsheet/rpi.md
Normal file
19
content/cheatsheet/rpi.md
Normal file
@@ -0,0 +1,19 @@
|
||||
---
|
||||
title: Raspberry Pi
|
||||
description: Tools, links and configuration for your Raspberry Pi
|
||||
tags:
|
||||
- rpi
|
||||
---
|
||||
|
||||
# HDMI flickering
|
||||
|
||||
Avoid HDMI flickering/intermittent blanking on RPI with a 1400x1050 VGA monitor.
|
||||
|
||||
```python
|
||||
|
||||
hdmi_drive=2
|
||||
hdmi_group=2
|
||||
hdmi_mode=42
|
||||
disable_overscan=1
|
||||
config_hdmi_boost=7
|
||||
```
|
Reference in New Issue
Block a user