This file contains hidden or 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
| #!/bin/bash | |
| # | |
| # Chrome Profile Lister | |
| # Lists all Google Chrome profiles with email addresses only | |
| # Format designed for easy selection and extraction in Keyboard Maestro | |
| # | |
| # Process command-line options | |
| SHOW_HEADER=true | |
| FORMAT="default" |
This file contains hidden or 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
| // Variables used by Scriptable. | |
| // These must be at the very top of the file. Do not edit. | |
| // icon-color: cyan; icon-glyph: bus; | |
| let [argsStop, topColorStr, bottomColorStr, textColorStr] = cleanParameters( | |
| args?.widgetParameter | |
| ); | |
| let topColor = new Color(topColorStr); | |
| let bottomColor = new Color(bottomColorStr); |
This file contains hidden or 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
| const cheerio = require("cheerio"); | |
| const got = require("got"); | |
| const fs = require("fs"); | |
| const hsk3URL = | |
| "https://resources.allsetlearning.com/chinese/grammar/HSK_3_grammar_points"; | |
| (async () => { | |
| const response = await got(hsk3URL); | |
| const $ = cheerio.load(response.body); |
This file contains hidden or 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 xmltodict | |
| from libvoikko import Voikko | |
| f = open("kotus-sanalista_v1.xml") | |
| text = f.read() | |
| f.close() | |
| kotus = xmltodict.parse(text) | |
| verbs = [x["s"] for x in kotus["kotus-sanalista"]["st"] if "t" in x and "tn" in x["t"] and int(x["t"]["tn"]) >= 52 and int(x["t"]["tn"]) <99 ] |
This file contains hidden or 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 os | |
| from PIL import Image | |
| desired_w = 300.0 | |
| bucket_name = "mybucket" | |
| files = [x for x in os.listdir() if x.endswith("jpg")] | |
| for i in files: |
This file contains hidden or 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
| from libvoikko import Voikko | |
| v = Voikko("fi") | |
| def adjective(w): | |
| analyzed = v.analyze(w) | |
| for item in analyzed: | |
| if "CLASS" in item and "laatusana" in item["CLASS"] and "SIJAMUOTO" in item and item[ | |
| "SIJAMUOTO"] == "nimento" and w == item["BASEFORM"]: | |
| return True | |
| return False |
This file contains hidden or 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 os.path | |
| import datetime | |
| text = """ | |
| # Release note | |
| Creating semi-autoupdated Python release notes with some timestamp magic. | |
| Timestamp updates when document is saved and/or is `touch`:ed by a build script. | |
| """ | |
| timestamp = datetime.datetime.fromtimestamp(os.path.getmtime("release_notes.py")).isoformat() |
This file contains hidden or 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
| package com.foo.RecyclerViewMatcher; | |
| import android.content.res.Resources; | |
| import android.support.v7.widget.RecyclerView; | |
| import android.view.View; | |
| import org.hamcrest.Description; | |
| import org.hamcrest.Matcher; | |
| import org.hamcrest.TypeSafeMatcher; |
This file contains hidden or 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
| <!DOCTYPE html> | |
| <meta charset="utf-8"> | |
| <link rel="stylesheet" href="http://cmx.io/v/0.1/cmx.css"> | |
| <script src="http://cmx.io/v/0.1/cmx.js" charset="utf-8"></script> | |
| <style>.cmx-user-scene4 .cmx-text-border .cmx-path {stroke: orange}</style> | |
| <body> | |
| <div style="max-width:900px; -webkit-transform:rotate(0deg)"> | |
| <scene id="scene1"> | |
| <label t="translate(0,346)"> |
This file contains hidden or 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
| # Prints out a tab separated line that includes short date format, placeholder for daily hours, double-slash, commit message and a full date in isoformat | |
| git log --reverse --date=short --format="%cd%x0908:00%x09%s%x2F%x2F%ci" |
NewerOlder