Forked from A Non Ymous's Pen sJAdx.
A Pen by Bryan Buchanan on CodePen.
title: Mesa # Human-readable theme name to be used in UI | |
name: mesa # camelCase theme name to be used by system | |
image: image.jpg # Name of theme preview image file | |
options: # List of categories of customizable properties | |
- name: logo | |
title: Logo | |
properties: | |
- image: true | |
name: logoImage |
require('dotenv').config() | |
const express = require('express') | |
const fetch = require('node-fetch') | |
const app = express() | |
app.use('/', async (req, res) => { | |
// Attachment URL | |
const attachmentURL = "https://trello.com/1/cards/5e65954f0f343116e999658f/attachments/5e67a146876719748d64057b/previews/5e67a147876719748d6405ae/download" |
import os | |
import sys | |
directory = os.path.dirname(os.path.realpath(sys.argv[0])) | |
for dirpath, dirnames, files in os.walk(directory): | |
if not files: | |
os.rmdir(dirpath) |
import os | |
import sys | |
directory = os.path.dirname(os.path.realpath(sys.argv[0])) | |
for subdir, dirs, files in os.walk(directory): | |
for filename in files: | |
if filename.find('old_suffix_1') > 0: | |
subdirectoryPath = os.path.relpath(subdir, directory) | |
filePath = os.path.join(subdirectoryPath, filename) |
Forked from A Non Ymous's Pen sJAdx.
A Pen by Bryan Buchanan on CodePen.
/* Save this file with a jsx extension and place in your | |
Illustrator/Presets/en_US/Scripts folder. You can then | |
access it from the File > Scripts menu */ | |
var decimalPlaces = 3; | |
if (app.documents.length > 0) { | |
if (app.activeDocument.selection.length < 1) { | |
alert('Select a path'); |
imgLoader = new Image(); | |
imgLoader.onload = function(data) { | |
// Desired size | |
var max_width = 600; | |
var max_height = 600; | |
// Get image dimensions | |
var original_width = imgLoader.width; | |
var original_height = imgLoader.height; |
<!doctype html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
</head> | |
<body> | |
<!-- Test image --> | |
<img src="http://m1.22slides.com/bryanbuchanan/4317_image_374612.jpg" alt="Image"> |
<?php | |
if (isset($_POST)) { | |
// Get user ID | |
$user_id = $_POST['user_id']; | |
// Data to send to Flickr API | |
$data = array( | |
"method" => "flickr.people.getInfo", | |
"user_id" => $user_id, |
// Function | |
function lltoXY(options) { | |
var x = (options.lon + 180) * (options.width / 360); | |
var y = ((options.lat * -1) + 90) * (options.height / 180); | |
return { x: x, y: y }; | |
} | |
// Usage | |
var position = lltoXY({ | |
lat: 25.26, |