Skip to content

Instantly share code, notes, and snippets.

View awesomephant's full-sized avatar
😤

Max Kohler awesomephant

😤
View GitHub Profile
@awesomephant
awesomephant / sharer-links.txt
Created August 23, 2021 10:31
Templates for pure HTML social share links
@awesomephant
awesomephant / makeUploadFolders.js
Created January 11, 2022 11:36
Seafile Scripts
const axios = require("axios");
const fs = require("fs")
const baseURL = "https://seafile.rlp.net"
let allUploadLinks = [];
let config = {
headers: {
"Authorization": "Token 565d9012b6c134e37233fb64172f6223fb584197",
'Accept': 'application/json; indent=4',
'Content-Type': 'application/x-www-form-urlencoded',
@awesomephant
awesomephant / .eleventy.js
Created May 6, 2023 09:03
Eleventy files for Ollie
const pluginRss = require("@11ty/eleventy-plugin-rss");
const markdownIt = require("markdown-it");
const replacements = require("./_data/replacements.json");
const Image = require("@11ty/eleventy-img");
const path = require("path");
const colors = require('colors');
const md = new markdownIt({
breaks: true,
});
<?php
function array_to_sentence($arr)
{
$s = "";
if (count($arr) === 1) {
$s = $arr[0];
} elseif (count($arr) === 2) {
$s = $arr[0] . " and " . $arr[1];
} else {
$slice = array_slice($arr, 0, count($arr) - 1);