Skip to content

Instantly share code, notes, and snippets.

View holazt's full-sized avatar
🐧
Learning everything...

Ahmed holazt

🐧
Learning everything...
  • Geeker
  • City of Science
View GitHub Profile
@holazt
holazt / gpg-tour.md
Created January 3, 2017 07:43 — forked from jhjguxin/gpg-tour.md
GPG 加密解密简明教程 </br> 作者: riku / 本文采用CC BY-NC-SA 2.5协议 授权

GPG 加密解密简明教程

大家都知道,互联网上充斥着大量的明文传输方式,可以说绝对是不安全地带。那么,我们如何保证在不安全的互联网中更可靠的传输重要数据呢?个人认为最好的方式之一就是使用 GPG 工具进行加密。此文只是简单介绍了 GPG 的常规用法,重在推广和普及 GPG 加密工具,详细的使用请参见 GPG 手册。

名词解释

RSA / DSA / ElGamal : 是指加密算法

GPG :(全称 GnuPG ) 是一款非对称加密(PGP)的免费软件,非对称加密方式简单讲就是指用公钥加密文件,用私钥解密文件。如果你想给谁发送加密信息,首先你要得到他的公钥,然后通过该公钥加密后传给他,对方利用自已的私钥就可解密并读取文件了。

@holazt
holazt / ip.set.bat
Created January 5, 2017 15:11 — forked from moolex/ip.set.bat
Windows下自动设置IP的批处理脚本
@echo off
::需要设置的网络,一般为“本地连接”或者“无线网络连接”
set name="无线网络连接"
::请根据您的参数修改以下数据
::设置 IP地址
set ipaddress=18.1.16.169
::设置 子掩码
set mask=255.255.252.0
::设置 网关
set gateway=18.1.19.254
@holazt
holazt / IP-DNS-swift-switch.cmd
Created January 7, 2017 05:05
Windows 下 IP 和 DNS 快速切换(批处理)
@echo off
title IP 和 DNS 快速切换
color 0a
rem 以下几个参数用户自行配置
rem name这个值,是你电脑网络连接的名称,
rem 需要到网络适配器中去查看
rem 大部分name值都是”本地连接”,
@holazt
holazt / install_intelr_graphic_linux_firmware.sh
Created March 26, 2017 05:58 — forked from zas/install_intelr_graphic_linux_firmware.sh
Fix "W: Possible missing firmware /lib/firmware/i915/kbl_dmc_ver1.bin for module i915_bpo" (Ubuntu 16.04, kernel 4.4)
#!/bin/bash
cd
wget https://01.org/sites/default/files/downloads/intelr-graphics-linux/sklgucver61.tar.bz2 && \
tar xvjf sklgucver61.tar.bz2 && cd skl_guc_ver6_1/ && sudo ./install.sh
cd
wget https://01.org/sites/default/files/downloads/intelr-graphics-linux/kbldmcver101.tar.bz2 && \
@holazt
holazt / Docker CE on Linux Mint 18.1
Created April 13, 2017 08:27
Docker CE on Linux Mint 18.1
Here are the instructions to installing Docker CE on Linux Mint 18.1 Serena.
Step1. `sudo apt-get install apt-transport-https ca-certificates curl software-properties-common`
Step2. `curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -`
The following line in the SOURCE automatically determines the distribution, which is Serena,
but there are no Linux Mint packages for Docker. You have to change it to the matching Ubuntu distribution.
FYI Linux Mint Serena is based on Ubuntu 16.04 Xenial.
@holazt
holazt / markdownhere.css
Created April 3, 2018 01:19 — forked from xiaolai/markdownhere.css
markdown-here-css
.markdown-here-wrapper {
font-size: 16px;
line-height: 1.8em;
letter-spacing: 0.1em;
}
pre, code {
font-size: 14px;
font-family: Roboto, 'Courier New', Consolas, Inconsolata, Courier, monospace;

STEPS

  • Click on Help menu

  • Select Enter License

  • Then paste given KEY given at bottom

  • Finally click on Use License

@holazt
holazt / README.MD
Created July 13, 2019 13:29 — forked from ihciah/README.MD
V2ray MTProto through Shadowsocks

V2ray MTProto through Shadowsocks

Why use it

The MTProto is easy to block; shadowsocks is hard to identify but cannot work without a client.

You can deylop this docker image to run a relay inside the firewall (China/Russia etc.), it provide a MTProto and all the packets will be sent through shadowsocks protocol.

How to run

@holazt
holazt / tex2clip.sh
Created March 28, 2020 03:42 — forked from psaikko/tex2clip.sh
Read LaTeX source from standard input, render to PNG and move to clipboard. Paste nice equations anywhere.
#!/usr/bin/env bash
tmpdir="$(mktemp -d)"
texfile="$tmpdir/tmp.tex"
echo "\documentclass[varwidth]{standalone}
\usepackage{amsmath,amsfonts,amssymb,amsthm}
\usepackage{color}
\usepackage[utf8]{inputenc}
\begin{document}
" > "$texfile"