Mix.install([
{:ollama, "~> 0.8.0"},
{:kino, "~> 0.15.3"},
])
Steps to setup a USB drive for use as installer for multiple Linux distributions without using any third-party tools. This is to avoid more convenient but potentially malware Ventoy.
IMPORTANT: Use fdisk -l
and dmesg
to identify the USB disk to use. Steps below assume /dev/sda
as the USB disk to target. If you pick a wrong disk, you would LOSE ALL DATA on that disk.
# Create two partitions
sudo fdisk /dev/sda
1 - EFI System (type=1): size=+1G
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
Z=$(curl -s https://ziglang.org/download/index.json | jq -r '.master."x86_64-linux".tarball') | |
OUT_DIR=$(echo "$Z" | awk -F "/" '{ print $NF }' | sed 's/.tar.xz//') | |
if [ -d "$OUT_DIR" ]; then | |
echo "Latest Zig already present: $OUT_DIR" | |
else | |
curl -s "$Z" | tar xJf - | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
## | |
# git-diffc: Graphical Git diff viewer | |
# 'c' -> comprehensive :) | |
# Author: Nitin Gupta <[email protected]> | |
# Last Modified (mm-dd-yy): 03/11/2020 | |
# | |
## |
Steps to install BCC and bpftrace from source on Ubuntu 18.04.
sudo apt-get -y install bison build-essential cmake flex git libedit-dev \
libllvm6.0 llvm-6.0-dev libclang-6.0-dev python zlib1g-dev libelf-dev \
iperf3 luajit libluajit-5.1-dev netperf linux-headers-$(uname -r)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/bash | |
set -e | |
# set up nux-dextop repo to install font packages. skip if this repo had already set up. | |
# can be done by either rpm or yum app. | |
# /usr/bin/sudo /usr/bin/rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm | |
/usr/bin/sudo /usr/bin/yum localinstall http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm | |
# disable nux-dextop by default and only enable it as needed as part of running yum. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define _GNU_SOURCE | |
#include <error.h> | |
#include <errno.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <sys/mman.h> | |
#include <sys/types.h> |
So basically FlowType doesn't know about CSS Modules, a really handy way of dealing with the plagues of CSS in codebases (global variables and dependency wackiness mainly).
What WebPack allows us to do is "require" CSS files and use their class names:
import styles from "my_styles.css";
import React from "react";
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Makefile: | |
(make sure Makefile is indented using a tab and not spaces) | |
all: | |
cc -Wall -g -O0 rdb_mergeop.c -o rdb_mergeop -lstdc++ -lrocksdb -lsnappy -lbz2 -llz4 -lz | |
clean: | |
rm -rf rdb_mergeop | |
rm -rf testdb | |
*/ |
NewerOlder