- Open Automator
- Create a new document
- Select Quick Action
- Set “Service receives selected” to
files or folders
inany application
- Add a
Run Shell Script
action- your default shell should already be selected, otherwise use
/bin/zsh
for macOS 10.15 (”Catalina”) or later - older versions of macOS use
/bin/bash
- your default shell should already be selected, otherwise use
- if you're using something else, you probably know what to do 😉
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
substitutions: | |
device_name: sonoff-pow-r3 | |
device_description: Sonoff Pow R3 | |
friendly_name: Sonoff Pow R3 | |
esphome: | |
name: ${device_name} | |
comment: ${device_description} | |
esp8266: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import socket | |
import asyncio | |
import websockets | |
import time | |
import logging | |
import argparse | |
import threading | |
import sys | |
To remove a submodule you need to:
- Delete the relevant section from the .gitmodules file.
- Stage the .gitmodules changes git add .gitmodules
- Delete the relevant section from .git/config.
- Run git rm --cached path_to_submodule (no trailing slash).
- Run rm -rf .git/modules/path_to_submodule (no trailing slash).
- Commit git commit -m "Removed submodule "
- Delete the now untracked submodule files rm -rf path_to_submodule
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* A key/value dict system in C */ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#define TEST TRUE /* Comment this line out to compile without a main function (used when including into another application). */ | |
typedef struct dict_t_struct { | |
char *key; | |
void *value; |