Skip to content

Instantly share code, notes, and snippets.

@dvygolov
dvygolov / showbmadacclimit.js
Created January 11, 2023 09:33
This script shows Ad Account creation limit for all Business Managers
var bms = await getAllBms();
for (let i = 0; i < bms.data.length; i++) {
let bm = bms.data[i];
console.log(
`%cProcessing BM: ${bm.name}`,
"font-size:15px;font-weight:bold;"
);
console.log(`Ad Account creation limit is: ${await getBMAdAccountCreationLimit(bm.id)}`);
}
@johnchandlerburnham
johnchandlerburnham / ATaxonomyOfSelfTypes.md
Last active May 2, 2024 16:33
A Taxonomy of Self Types

A Taxonomy of Self-Types

Part I: Introduction to Self-Types

Datatypes in the Formality programming language are built out of an unusual structure: the self-type. Roughly speaking, a self-type is a type that can depend or be a proposition on it's own value. For instance, the consider the 2 constructor datatype Bool:

@james-d
james-d / PlutoExplorer.java
Last active May 2, 2024 16:33
Zoomable and Pannable JavaFX ImageView Example
import javafx.application.Application;
import javafx.beans.property.ObjectProperty;
import javafx.beans.property.SimpleObjectProperty;
import javafx.geometry.Insets;
import javafx.geometry.Point2D;
import javafx.geometry.Pos;
import javafx.geometry.Rectangle2D;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.control.Hyperlink;
// ==UserScript==
// @name TweetXer
// @namespace https://gist.github.com/lucahammer/a4d1e957ec9e061e3cccafcbed599e16/
// @version 0.5
// @description Delete all your Tweets for free.
// @author Luca
// @match https://twitter.com/*
// @icon https://www.google.com/s2/favicons?domain=twitter.com
// @grant unsafeWindow
// ==/UserScript==
@stereokai
stereokai / gist:36dc0095b9d24ce93b045e2ddc60d7a0
Last active May 2, 2024 16:31
CSS rounded corners with gradient border
.rounded-corners-gradient-borders {
width: 300px;
height: 80px;
border: double 4px transparent;
border-radius: 80px;
background-image: linear-gradient(white, white), radial-gradient(circle at top left, #f00,#3020ff);
background-origin: border-box;
background-clip: padding-box, border-box;
}
@ConnerWill
ConnerWill / ANSI-escape-sequences.md
Last active May 2, 2024 16:30
ANSI Escape Sequences cheatsheet

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27

转载粉丝日志 #在Ubuntu上安装PPTP VPN服务

1. 使用apt源服务来安装PPTPD服务

sudo apt-get update
sudo apt-get install pptpd

2. 安装完成之后编辑pptpd.conf配置文件

sudo vim /etc/pptpd.conf

@gyribeiro
gyribeiro / tmux_italic.md
Last active May 2, 2024 16:28
enable italic font on tmux
@faiyaz7283
faiyaz7283 / watchlist_heatmap.pinescript
Last active May 2, 2024 16:27
Watchlist heatmap for Trading View
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © faiyaz7283
//@version=5
indicator(title="Watchlist Heatmap", shorttitle="WL Heatmap", overlay=true)
// ::Imports:: {
import faiyaz7283/tools/9 as tools
import faiyaz7283/printer/6 as prnt
@alejandro-martin
alejandro-martin / multiple-ssh-keys-git.adoc
Last active May 2, 2024 16:27
Configure multiple SSH Keys for Git

Use Multiple SSH Keys for Git host websites (Github, Gitlab)

This is guide about how to configure multiple SSH keys for some Git host websites such as Github, Gitlab, among others.

Creating SSH keys

  1. Create SSH directory: