Skip to content

Instantly share code, notes, and snippets.

@asamofal
asamofal / update_bions_lenovo_x1_g6.md
Created April 18, 2020 21:50
Update BIOS on ThinkPad X1 Carbon Gen 6th (Ubuntu 18.04, Legacy mode)

Update BIOS on ThinkPad X1 Carbon Gen 6th (Ubuntu 18.04)

Laptop (ThinkPad) Lenovo X1 Carbon 6th Gen (Type 20KH, 20KG)

If you are using your ThinkPad X1G6 with Linux in "Legacy only" mode, there's only one way how to update BIOS - you should use "BIOS Update (Bootable CD)". So this is a step by step guid how to do it.

Check current BIOS version:

fwupdmgr get-devices

@guest271314
guest271314 / javascript_engines_and_runtimes.md
Last active March 29, 2024 01:46
A list of JavaScript engines, runtimes, interpreters

V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++. It is used in Chrome and in Node.js, among others. It implements ECMAScript and WebAssembly, and runs on Windows 7 or later, macOS 10.12+, and Linux systems that use x64, IA-32, ARM, or MIPS processors. V8 can run standalone, or can be embedded into any C++ application.

SpiderMonkey is Mozilla’s JavaScript and WebAssembly Engine, used in Firefox, Servo and various other projects. It is written in C++, Rust and JavaScript. You can embed it into C++ and Rust projects, and it can be run as a stand-alone shell. It can also be [compiled](https://bytecodealliance.org/articles/making-javascript-run-fast-on

@swiftui-lab
swiftui-lab / grid-trainer.swift
Last active March 29, 2024 01:46
A grid trainer for Grid views
// Author: SwiftUI-Lab (swiftui-lab.com)
// Description: this learning tool is designed to showcase the different
// Grid and GridRow view options, added in SwiftUI 2022. It is part of the
// blog article: https://swiftui-lab.com/eager-grids
//
import SwiftUI
import UniformTypeIdentifiers
// The root view of the application
struct ContentView: View {
@kishida
kishida / SevenGame.java
Last active March 29, 2024 01:45
7並べゲーム
/*
* to run, use Java 22 or later
* java --enable-preview --source 22 SevenGame.java
*/
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.net.ServerSocket;
import java.nio.charset.Charset;
import java.util.ArrayList;
@1Marc
1Marc / reactive.js
Last active March 29, 2024 01:43
Vanilla Reactive System
// Credit Ryan Carniato https://frontendmasters.com/courses/reactivity-solidjs/
let context = [];
export function untrack(fn) {
const prevContext = context;
context = [];
const res = fn();
context = prevContext;
return res;
@aparrish
aparrish / understanding-word-vectors.ipynb
Last active March 29, 2024 01:40
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7) Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@rcknr
rcknr / add2books.html
Created May 30, 2013 08:27
Add PDF and EPUB files from your Google Drive to Google Books.
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title>Add to Google Books</title>
<script src="//www.google.com/jsapi"></script>
<script src="//apis.google.com/js/client.js"></script>
<script type="text/javascript">
@mrpmorris
mrpmorris / ConsoleApp153.csproj
Last active March 29, 2024 01:39
Proof that automapper can be faster than your own manually written code
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>