Skip to content

Instantly share code, notes, and snippets.

@LM1LC3N7
LM1LC3N7 / Readme.md
Last active April 25, 2024 18:39
Automating application install on a fresh Windows 10/11 using Microsoft Store and winget

FASIC

Fast and Automatic Software Install and Configuration (on Windows)

Need

Install my common apps on Windows as fast as possible and mostly automatically, after a reimaging or reset of my OS. Also change some settings on Windows, like disabling the bing search in the start menu.

How it works?

This PowerShell script uses Microsoft Store and winget to download and install a list of application, configured at the top of the file.

@LM1LC3N7
LM1LC3N7 / README.md
Last active January 27, 2022 10:48
Tmux configuration

Tmux compilation & config

tmux

Tested on CentOS 8 and Oracle Linux 8, should work on CentOS 7 by replacing dnf with yum.

Before all, edit /etc/environment and set:

TERM=screen-256color
@LM1LC3N7
LM1LC3N7 / README.md
Last active November 2, 2023 12:54
SSH PAM module - Telegram Alert on connect and disconnect, with IP exceptions.

SSH Telegram configuration

telegram

Bot creation

  1. Open your app and search for @BotFather, or open this link: https://telegram.me/botfather.
  2. Type /newbot
  3. Name your new bot (this is the contact name, like "Bot My server")
  4. Give it a unique Telegram name, ending with bot(like "my_server_bot")
  5. Now, you should see a token: keep it safe!
@LM1LC3N7
LM1LC3N7 / script-iptables.sh
Last active January 17, 2023 00:07
Script de paramétrage de IPTables
#!/bin/bash
## SOURCE
## - https://github.com/trimstray/iptables-essentials
## - https://gist.github.com/azlux/6a70bd38bb7c525ab26efe7e3a7ea8ac
#
# =============
# Configuration
# =============
@LM1LC3N7
LM1LC3N7 / MultimediaKeys.ahk
Last active September 17, 2023 10:14
Add some multimedia keys and bind Windows 10's desktop management keys to a mouse (without return and forward buttons) using AutoHotKey. Use a .bat script to launch those 2 AutoHotKey scripts.
;
; This is an AutoHotKey script that bind "CTRL + SHIFT + MOUSE SCROLL" to:
; - Volume Up (Scroll up)
; - Volume Down (Scroll down)
; - Volume Mute (Scroll Middle click)
;
; And also mouse wheel left and right to:
; - Back
; - Forward
;
@LM1LC3N7
LM1LC3N7 / create_docker_volumes_and_networks.sh
Last active April 4, 2018 13:04
Script to easily create docker networks and volumes
#!/bin/bash
#
# Execute:
# chmod +x create_docker_volumes_and_networks.sh
# ./create_docker_volumes_and_networks.sh
#
# Verify docker networks and docker network cards:
# docker network ls
# ip a
@LM1LC3N7
LM1LC3N7 / openapi.yaml
Created March 26, 2018 13:31
OpenAPI version 3.0 for Swagger Editor & Swagger UI - Exemple
#### INFOS ####
openapi: "3.0.0"
info:
version: <PROJET VERSION>
title: <PROJET NAME>
description: >-
Multiline description allowed.
<br/>
<br/>
Lines jumps using `<br/>` are also possibles and Markdown
@LM1LC3N7
LM1LC3N7 / requireHandleErrors.js
Last active February 28, 2018 11:26
Require a module and catch errors when it is not installed nor finded
//
// To test this:
// 1) node requireHandleErrors.js
//
// Output should be:
// $ node requireHandleErrors.js
// Module "moduleNotFound" not found. Maybe it is not installed yet?
//
//
@LM1LC3N7
LM1LC3N7 / https_srv.js
Last active February 28, 2018 11:25
Start a new expressjs https web server, using a valid certificate or a new auto generated self signed one and handle SIGINT to exit gracefully
//
// To test this:
// 1) npm install express fs https pem
// 2) node https_srv.js
// 3) open a new webpage on http://127.0.0.1
//
// Provide here a valid key file and crt file to run a valid https server
// Invalid path will force the app to generate a self signed certificate
let certsFiles = {