Skip to content

Instantly share code, notes, and snippets.

View RouHim's full-sized avatar
⌨️

Rouven Hi! RouHim

⌨️
View GitHub Profile
@peteristhegreat
peteristhegreat / Readme.md
Last active April 12, 2024 07:32
Realtek bluetooth usb adapter RTL8671b
@wojteklu
wojteklu / clean_code.md
Last active May 6, 2024 09:35
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@steinwaywhw
steinwaywhw / One Liner to Download the Latest Release from Github Repo.md
Last active May 5, 2024 20:02
One Liner to Download the Latest Release from Github Repo
  • Use curl to get the JSON response for the latest release
  • Use grep to find the line containing file URL
  • Use cut and tr to extract the URL
  • Use wget to download it
curl -s https://api.github.com/repos/jgm/pandoc/releases/latest \
| grep "browser_download_url.*deb" \
| cut -d : -f 2,3 \
| tr -d \" \
@samie
samie / App.java
Last active February 15, 2018 15:41
Minimal Standalone Vaadin Application Jar with Maven (~ 7.7MB)
package org.vaadin.lightvaadin;
import com.vaadin.server.VaadinServlet;
import java.util.EventListener;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.eclipse.jetty.server.Server;
import org.eclipse.jetty.servlet.ServletContextHandler;
import org.eclipse.jetty.servlet.ServletHolder;
@willurd
willurd / web-servers.md
Last active May 6, 2024 09:12
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000