Skip to content

Instantly share code, notes, and snippets.

View schlos's full-sized avatar

Miroslav schlos

View GitHub Profile
@schlos
schlos / README.md
Created November 8, 2017 21:51 — forked from rbren/README.md
Sync GitHub issues to spreadsheet

DataFire Dataflow: Sync GitHub issues to spreadsheet

Pulls all new issues from a GitHub repo into a spreadsheet

View on DataFire

[metadata]: ./ '{"links":[{"connection":"563b9b84ea9ad5f345e97505","operation":{"method":"get","path":"/repos/{ownerId}/{repoId}/issues"}},{"connection":"563b9b85ea9ad5f345e97511","operation":{"method":"get","path":"/list/{key}/{worksheetId}/{visibility}/{projection}"}},{"connection":"563b9b85ea9ad5f345e97511","operation":{"method":"put","path":"/cells/{key}/{worksheetId}/{visibility}/{projection}/{cellId}"}},{"connection":"563b9b85ea9ad5f345e97511","operation":{"method":"post","path":"/list/{key}/{worksheetId}/{visibility}/{projection}"}},{"connection":"563b9b85ea9ad5f345e97511","operation":{"method":"put","path":"/list/{key}/{worksheetId}/{visibility}/{projection}/{rowId}"}}],"constants":[{"name":"spreadsheetID","description":"The ID of your spreadsheet from its URL: docs.google.com/spreadsheets/d/SPREADSHEET_ID","type":

Linux System Metrics

CPU

  • system.cpu.idle: % Idle CPU
  • system.cpu.system: % System CPU
  • system.cpu.user: % User CPU

Disk

@schlos
schlos / Time-based.Gmail.Email.Purge.Script.gs
Last active June 18, 2017 11:29 — forked from dgibbs64/GmailAutoTrash.gscript
Gmail/Inbox Email Purge Script
// Gmail/Inbox Email Purge Script
// Using Google Script
// Clears out all emails older than X days
// Labels
function multipleLabels() {
var myLabels = {
'"Updates"': "7d",
'"Forums"': "7d",
'"Promotions"': "7d",
@schlos
schlos / gmail-snooze.js
Created June 18, 2017 11:20 — forked from ViViDboarder/gmail-snooze.js
Gmail Snooze
/*
Gmail Message Snoozing
Quick implementation to allow snoozing of unread messages in Gmail
Usage:
The move unread emails into a snooze label for the desired snooze time. After
the specified time, the message should be moved back into your inbox. This will
only effect unread emails to prevent messages from continuing to bounce back
@schlos
schlos / Gmail-Scheduler.gs
Last active June 18, 2017 11:16 — forked from dwerbam/Code.gs
Gmail Scheduler
function installScript() {
// Makes sure that only 1 scheduler is installed
uninstallScript();
// Trigger every 1 hour.
ScriptApp.newTrigger('gmailScheduler')
.timeBased()
.everyHours(1)
.create();
// ==UserScript==
// @name gmail-enhancer
// @namespace gmail-enhancer
// @description gmail-enhancer UX experience
// @include https://mail.google.com/mail/*
// @version 1.2
// @grant none
// ==/UserScript==
(function() {
@schlos
schlos / .en.md
Created June 18, 2017 11:13 — forked from oshliaer/.en.md
Gmail checker
@schlos
schlos / Clean GMail.js
Created June 18, 2017 11:11
Clean GMail
// This script retrieves contents of Gmail Inbox and leaves only
// predefined amount of last messages. Old messages will be
// moved to archive.
function cleanOld(){
var old_threads = GmailApp.getInboxThreads();
var leave = 30;
if (old_threads.length>=leave){
for (var i=leave; i<old_threads.length; i++){
@schlos
schlos / gmail-snooze.js
Created June 18, 2017 11:11
GMail Snooze Script
var LABEL = 'Snooze';
var MONTHS = 1;
var MARK_UNREAD = true;
var ADD_UNSNOOZED_LABEL = true;
function dailySnooze() {
var today;
var page;
var d = new Date();
var day = d.getDate();
@schlos
schlos / gh-gmail-label-script.js
Created June 18, 2017 11:08 — forked from cobyism/gh-gmail-label-script.js
GitHub Email Notification labeller script for Google Apps/Gmail
var my_teams = ["@github/css", "@github/design"] // Add any teams you want autodetected to this list
var base_label = ["GitHub"]
var my_teams_regex = new RegExp('(' + my_teams.join('|') + ')')
function GitHubThread(thread) {
this._thread = thread
// Determine why we got this message and label the thread accordingly.
//