Skip to content

Instantly share code, notes, and snippets.

@wavezhang
wavezhang / java_download.sh
Last active December 26, 2024 18:08
download java from oracle without login
wget -c --no-cookies --no-check-certificate --header "Cookie: oraclelicense=accept-securebackup-cookie" https://download.oracle.com/otn-pub/java/jdk/12.0.2+10/e482c34c86bd4bf8b56c0b35558996b9/jdk-12.0.2_linux-x64_bin.tar.gz
@TheSandvichMaker
TheSandvichMaker / .readme.md
Last active December 26, 2024 18:03
Implementation of David Eberly's mesh clipping algorithm
@benixal
benixal / worker.js
Last active December 26, 2024 18:01
Free Telegram Upload Center
/*
https://github.com/benixal
https://www.youtube.com/@benixal
*/
export default {
// @ts-ignore
async fetch(request, env, ctx) {
// Handle-based array. Used like this:
//
// Entity_Handle :: distinct Handle
// entities: Handle_Array(Entity, Entity_Handle)
//
// It expects the type used (in this case
// Entity) to contains a field called
// `handle`, of type `Entity_Handle`.
//
// You can then fetch entities using
@joeljerushan
joeljerushan / PaginateApp.js
Last active December 26, 2024 17:58
React Pagination with Firebase FireStore - (Prev / Next Pagination)
import React, { useState, useEffect } from 'react'
//i'm using react-bootstrap for UI elements
import { Table, Button, ButtonGroup } from "react-bootstrap";
//firebase config
import firebase from './../../Firebase'
export default function App() {
const [list, setList] = useState([]);
const [page, setPage] = useState(1);
@brev
brev / unix_cookbok.md
Last active December 26, 2024 17:57
Unix Cookbook

Unix Cookbook

System

Find system naming:

uname  # os
uuname -l  # short
uname -a # detailed
@gustavovalverde
gustavovalverde / gh-environment-manager.sh
Last active December 26, 2024 17:56
A bash script to handle GitHub environment variables, mainly to create new environments, and copy variables values from one environment to another
#!/bin/bash
# MIT License
# Copyright (c) 2024 Gustavo A. Valverde
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@Changaco
Changaco / btrfs-undelete
Last active December 26, 2024 17:55
btrfs-undelete
#!/bin/bash
# btrfs-undelete
# Copyright (C) 2013 Jörg Walter <[email protected]>
# This program is free software; you can redistribute it and/or modify it under
# the term of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or any later version.
if [ ! -b "$1" -o -z "$2" -o -z "$3" ]; then
echo "Usage: $0 <dev> <file/dir> <dest>" 1>&2
echo
@Yatoom
Yatoom / setup.md
Last active December 26, 2024 17:54
Thinkfan configuration

Thinkfan setup

Note: I configured this thinkfan setup for my old Thinkpad w520 on Ubuntu 17.10.

1. Install necessary programs

Install lm-sensors and thinkfan.

sudo apt-get install lm-sensors thinkfan