Skip to content

Instantly share code, notes, and snippets.

@pojntfx
pojntfx / main.sh
Last active July 16, 2024 10:21
Bluesky/AT Protocol: cURL API Interaction Cheatsheet
#!/bin/bash
# This script resolves a DID, retrieves an API key, fetches a user's feed,
# and posts a "Hello, world" message to the user's feed.
# Resolve DID for handle
HANDLE='felicitas.pojtinger.com'
DID_URL="https://bsky.social/xrpc/com.atproto.identity.resolveHandle"
export DID=$(curl -G \
--data-urlencode "handle=$HANDLE" \
@rudimusmaximus
rudimusmaximus / queryASpreadsheet.gs
Last active November 4, 2019 16:07
Follow up to Totally UnScripted Episode 3: SQL like queries in Google Apps Script
/**
* quickly test our function
*/
function test(){
var result = queryASpreadsheet('1sPevvtTMSd9LUptX8qdsw4VJf07nOal_1qn9JLwO4fQ',
'Example Data',
'A1:C',
'SELECT A,B,C WHERE B < 7');
var rows = result.length;//7
@St3ph-fr
St3ph-fr / gist:3247014
Created August 3, 2012 12:11
Google Apps Script - List de the public file of the DocsList in Google Apps Script
// #GoogleAppsScript #Gscript #GoogleSpreadsheet
function getPublicFiles(){
var ss = SpreadsheetApp.getActiveSpreadsheet();
var docs = DocsList.getFiles(); //Retrieve all the docs.
var listfile = "";
var viewer = new Array;
var owner = "";
var me = Session.getUser().getEmail(); //Get the email of the script owner. Need it to check if you are the owner of the file.
for(var i in docs){