# -s : Short output format
exiftool file.jpg -s
exiftool file.jpg -AllDates
exiftool file.jpg -FileModifyDate
exiftool file.jpg -DateTimeOriginal
exiftool 20170411_220635.JPG -s | grep Date
exiftool -p "$DateTimeOriginal" "Photo - 01.JPG"
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
const express = require("express"); | |
const cors = require("cors") | |
const { join } = require("path"); | |
const { parse } = require("url"); | |
const next = require("next"); | |
const fetch = require("isomorphic-unfetch") | |
const LRUCache = require('lru-cache') | |
const port = parseInt(process.env.PORT, 10) || 3000; | |
const dev = process.env.NODE_ENV !== "production"; |
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
const SWPrecacheWebpackPlugin = require('sw-precache-webpack-plugin') | |
module.exports = { | |
webpack: (config) => { | |
config.plugins.push( | |
new SWPrecacheWebpackPlugin({ | |
verbose: true, | |
staticFileGlobsIgnorePatterns: [/\.next\//], | |
runtimeCaching: [ | |
{ |
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
[ | |
{'city': 'Abbeville', 'state': 'Louisiana'}, | |
{'city': 'Aberdeen', 'state': 'Maryland'}, | |
{'city': 'Aberdeen', 'state': 'Mississippi'}, | |
{'city': 'Aberdeen', 'state': 'South Dakota'}, | |
{'city': 'Aberdeen', 'state': 'Washington'}, | |
{'city': 'Abilene', 'state': 'Texas'}, | |
{'city': 'Abilene', 'state': 'Kansas'}, |
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
/* ---- | |
css custom properties to manipulate color | |
MIT - 2017 - Soft Punch | |
https://gist.github.com/softpunch/ | |
set initial "main" color via HSL values. | |
automatically calculate harmonies and variations of that color with pure css. | |
harmonies are determined solely by hue. |
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
// generic use of SDK | |
var account = new CloudStorageAccount(credentials, true); | |
var client = new CloudBlobClient(account.BlobEndpoint.AbsoluteUri, account.Credentials); | |
var container = client.GetContainerReference("test"); | |
var blob = container.GetBlobReference("CloudBlob.txt"); | |
using (var stream = blob.OpenRead()) | |
{ | |
using (var reader = new StreamReader(stream)) | |
{ |
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
- Follow standard conventions.
- Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
- Boy scout rule. Leave the campground cleaner than you found it.
- Always find root cause. Always look for the root cause of a problem.
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
/** | |
* Run a callback over all children of a given element using depth-first | |
* traversal. | |
* | |
* @param {HTMLElement} element | |
* @param {Function} callback | |
*/ | |
function iterateDOM(element, callback) { | |
const nodes = []; |
CSS class names quickly get out of hand. Repos end up with unorganized CSS files all over the place making it difficult to name things and find them in the code.
The scoped components pattern addresses this by grouping classes into "component" scopes.
<div data-component="news-menu">
<h1 class="title">...</h1>
<ul class="items">
...
Last updated: 2017-03-18
exiftool -filename -filemodifydate -createdate -r -if '(not $datetimeoriginal) and $filetype eq "JPEG"' .
###Output photos that don't have datetimeoriginal to a CSV### Note this can take a long time if you have a lot of jpgs
NewerOlder