Standard escape codes are prefixed with Escape
:
- Ctrl-Key:
^[
- Octal:
\033
- Unicode:
\u001b
- Hexadecimal:
\x1B
- Decimal:
27
package com.pascaldimassimo.xyz; | |
import java.util.HashMap; | |
import java.util.Map; | |
import javax.persistence.EntityManagerFactory; | |
import javax.sql.DataSource; | |
import org.hibernate.cfg.ImprovedNamingStrategy; | |
import org.springframework.beans.factory.annotation.Autowired; |
/** | |
* Here is the jdk8 datetime cheatsheet and explanation why we use ZonedDateTime and Instant in TimeService. | |
*/ | |
// this is the 01.03.2016 00:00 in server timezone (Europe/Warsaw) == EXACTLY THE SAME AS THE SYSTEM TIME | |
ZonedDateTime zonedDateTime = ZonedDateTime.of(2016, 3, 1, 0, 0, 0, 0, ZoneId.systemDefault()); | |
System.out.println(zonedDateTime); // 2016-03-01T00:00+01:00[Europe/Warsaw] | |
// this is the same 01.03.2016 00:00 but doesn't carry timezone information | |
LocalDateTime localDateTime = zonedDateTime.toLocalDateTime(); |
# One line install | |
echo -e "g\nn\n\n\n+100M\nt\n1\nn\n\n\n+1G\nn\n\n\n\n\nw\nq\n" | fdisk /dev/sda && mkfs.vfat -F32 /dev/sda1 && mkswap /dev/sda2 && mkfs.ext4 /dev/sda3 && swapon /dev/sda2 && mount /dev/sda3 /mnt && mkdir -p /mnt/{boot/efi,home} && mount /dev/sda1 /mnt/boot/efi && pacstrap /mnt base base-devel && genfstab -p /mnt >> /mnt/etc/fstab && echo -e "echo NomDeLaMachine > /etc/hostname && echo '127.0.1.1 NomDeLaMachine.localdomain NomDeLaMachine' >> /etc/hosts && rm -f /etc/localtime && ln -s /usr/share/zoneinfo/Europe/Paris /etc/localtime && echo 'fr_FR.UTF-8 UTF-8' >> /etc/locale.gen && locale-gen && echo 'LANG=fr_FR.UTF-8' > /etc/locale.conf && echo KEYMAP=fr > /etc/vconsole.conf && mkinitcpio -p linux" | arch-chroot /mnt && echo -e "pacman --noconfirm -Syu xorg-server xorg-xinit xorg-server-utils xf86-video-intel xf86-input-synaptics gdm gnome networkmanager terminator emacs atom gcc valgrind firefox chromium git openssh" | arch-chroot /mnt && echo -e "useradd -Nm -g users -G wheel,sys epitech_ |
GNOME's tracker is a CPU and privacy hog. There's a pretty good case as to why it's neither useful nor necessary here: http://lduros.net/posts/tracker-sucks-thanks-tracker/
After discovering it chowing 2 cores, I decided to go about disabling it.
Directories
# Download: http://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html | |
sudo apt-get install alien | |
sudo alien -k --scripts sqldeveloper*.rpm | |
sudo dpkg -i sqldeveloper*.deb | |
mkdir -p ~/.sqldeveloper | |
# Paste the JDK path inside (/usr/lib/jvm/java-1.6.0-openjdk-i386) | |
vim ~/.sqldeveloper/jdk |
// Ansi colors in Groovy | |
// Author: Ted Vinke | |
import static Ansi.* | |
println color("BOLD", Ansi.BOLD) | |
println color("ITALIC", Ansi.ITALIC) | |
println color("UNDERLINE", Ansi.UNDERLINE) | |
println color("BLINK", Ansi.BLINK) | |
println color("RAPID_BLINK", Ansi.RAPID_BLINK) | |
println color("REVERSE_VIDEO", Ansi.REVERSE_VIDEO) |
deb http://archive.ubuntu.com/ubuntu/ focal main restricted universe multiverse | |
deb-src http://archive.ubuntu.com/ubuntu/ focal main restricted universe multiverse | |
deb http://archive.ubuntu.com/ubuntu/ focal-updates main restricted universe multiverse | |
deb-src http://archive.ubuntu.com/ubuntu/ focal-updates main restricted universe multiverse | |
deb http://archive.ubuntu.com/ubuntu/ focal-security main restricted universe multiverse | |
deb-src http://archive.ubuntu.com/ubuntu/ focal-security main restricted universe multiverse | |
deb http://archive.ubuntu.com/ubuntu/ focal-backports main restricted universe multiverse |
Create an empty git repo or reinitialize an existing one
git init