Skip to content

Instantly share code, notes, and snippets.

View rriemann's full-sized avatar

Robert Riemann rriemann

View GitHub Profile
@klingtnet
klingtnet / how-to-upgrade-nvmw-ssd-firmware-on-linux.md
Last active June 13, 2024 04:29
How to upgrade [Lenovo] NVMe SSD firmware on Linux

The instructions were tested on a Lenovo X1 Carbon 5th Gen (X1C5) on Arch Linux but should be applicable to other Lenovo models and Linux distributions.

BACKUP YOUR DATA! I created a bootable Ubuntu Image like this:

$ sudo sh -c 'curl --location --silent --fail "http://releases.ubuntu.com/18.04/ubuntu-18.04.1-desktop-amd64.iso" | pv > /dev/<your-usb-drive>'
# note that pv is only there to show progress, it is perfectly fine to redirect curl to the usb drive directly.

then I booted from this drive by pressing F12 on reboot and dumped my NVMe disk to an external hard drive like this:

anonymous
anonymous / overpass.geojson
Created June 23, 2017 12:58
data exported by overpass turbo
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#!/bin/bash
# pdfScale.sh
#
# Scale PDF to specified percentage of original size.
# Ref: http://ma.juii.net/blog/scale-page-content-of-pdf-files.
echo "This script doesn't handle files with spaces in them."
SCALE=0.95 # scaling factor (0.95 = 95%, e.g.)
@woodworker
woodworker / jekyll.ics
Created September 27, 2013 08:39
a jekyll template for icalendar file
---
layout: none
---
BEGIN:VCALENDAR
VERSION:2.0
PRODID:http://www.example.com/
METHOD:PUBLISH
{% for post in site.posts limit:10 %}BEGIN:VEVENT
UID:{{ post.date | date: "%Y%m%d" }}@example.com
ORGANIZER;CN="Organizer Name":MAILTO:organizer@example.org
#!/bin/bash
## Install Gitlab 5.2 on OpenSUSE 12.3 32Bits
## Project http://gitlab.org/
## Base https://github.com/gitlabhq/gitlabhq/blob/5-0-stable/doc/install/installation.md
## Autor: Nilton OS -- Version 0.9 14-06-2013 -- http://wwww.linuxpro.com.br/blog
## Change Vars !!!
SERVER_IP="10.0.2.15"
SERVER_FQDN="gitlab.linuxpro.com.br"
DOMIAN="linuxpro.com.br"
[Unit]
Description=Gitlab Resque Worker
Requires=redis.service
After=redis.service
Wants=postfix.service mysqld.service
[Service]
Type=forking
User=git
WorkingDirectory=/home/git/gitlab
@dhulihan
dhulihan / config.rb
Created January 21, 2013 22:39
middleman sitemap generator
# config.rb
page "/sitemap.xml", :layout => false
@sukima
sukima / photos_tag.rb
Created May 8, 2012 01:33
Jekyll Plugin for easy FancyBox usage
# Title: Photos tag for Jekyll
# Authors: Devin Weaver
# Description: Allows photos tag to place photos as thumbnails and open in fancybox. Uses a CDN if needed.
#
# ** This only covers the markup. Not the integration of FancyBox **
#
# To see an unabridged explination on integrating this with [FancyBox][1]
# Please read my [blog post about it][2].
#
# [1]: http://fancyapps.com/fancybox/