Skip to content

Instantly share code, notes, and snippets.

View kristoferlund's full-sized avatar
👨‍💻

Kristofer kristoferlund

👨‍💻
View GitHub Profile
@kristoferlund
kristoferlund / keymaps.lua
Created October 8, 2025 07:37
Toggle persistent terminal on the right: <leader>fr
-- Toggle persistent terminal on the right: <leader>fr
local function toggle_right_term()
_G.right_term_buf = _G.right_term_buf or nil
-- If we already have a term buffer, see if it's visible; if so, hide its window.
if _G.right_term_buf and vim.api.nvim_buf_is_valid(_G.right_term_buf) then
for _, win in ipairs(vim.api.nvim_list_wins()) do
if vim.api.nvim_win_get_buf(win) == _G.right_term_buf then
vim.api.nvim_win_close(win, true) -- hides buffer; process keeps running
return
@kristoferlund
kristoferlund / contracts...CattsCredits_flattened.sol
Created April 10, 2024 13:12
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.25+commit.b61c2a91.js&optimize=false&runs=200&gist=
// File: @openzeppelin/contracts/utils/Context.sol
// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)
pragma solidity ^0.8.20;
/**
* @dev Provides information about the current execution context, including the
{"openapi":"3.0.0","paths":{"/api/activate":{"post":{"operationId":"ActivateController_activate","summary":"Activate a user account in order to be able to give praise and receive rewards. Activation a user account creates a new User object or adds user account to User if it already exists.","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivateInputDto"}}}},"responses":{"200":{"description":"The created (or updated) user.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}}},"201":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/User"}}}}},"tags":["Activate"]}},"/api/users/export":{"get":{"operationId":"UsersController_export","summary":"Export users document to json or csv","parameters":[{"name":"format","required":false,"in":"query","schema":{"default":"csv","enum":["csv","json","parquet"],"type":"string"}}],"responses":{"200":{"description":"","content":{"application/json
'use strict';
(() => {
const functors = [
// === functors[0] ===
(({ imports: $h‍_imports, liveVar: $h‍_live, onceVar: $h‍_once, importMeta: $h‍____meta, }) => { $h‍_imports([]); /* global globalThis */
/* eslint-disable no-restricted-globals */
/**
* commons.js
* Declare shorthand functions. Sharing these declarations across modules
const manifest = {
name: "simple-report",
displayName: "Simple Report",
description: "A simple report.",
version: "1.2.3",
author: "General Magic",
publisher: "general-magic",
license: "MIT",
repository: "https://github.com/givepraise/praise-reports",
bugs: "https://github.com/givepraise/praise-reports/issues",
{
"name": "Gnosis Safe, CSV Airdrop, Straight Curve with Ceiling",
"map": {
"item": {
"token_type": "",
"token_address": "",
"receiver": "rewardsEthAddress",
"amount": "scoreRealized",
"id": ""
},
{
"name": "Aragon, Straight Curve with Ceiling",
"map": {
"item": {
"address": "rewardsEthAddress",
"amount": "scoreRealized",
"token": ""
},
"operate": [
{
{
"name": "Aragon fixed budget",
"map": {
"item": {
"address": "rewardsEthAddress",
"amount": "scoreRealized",
"token": "",
"a": "scoreRealized"
},
"operate": [
{
"name": "Receiver, count and score",
"map": {
"item": {
"address": "rewardsEthAddress",
"count": "praiseCount",
"score": "scoreRealized"
},
"operate": []
},

506bdngs18