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
function doResizeArtboards(width, height) { | |
if (app.documents.length === 0) { | |
alert("There are no open documents."); | |
return; | |
} | |
var theDoc = app.activeDocument; | |
try { | |
for (i = 0; i < theDoc.artboards.length; i++) { | |
/** |
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
function getExportOptionsSVG() { | |
var exportOptions = new ExportOptionsSVG(); | |
/** | |
* A range of artboards to save, if saveMultipleArtboards is true. A comma-delimited list of artboard names., or the empty string to save all artboards. Default: empty String. | |
* {string} | |
* | |
* NOTE: Set to an empty string to export all. Be sure `saveMultipleArtboards` is set to true to use this. | |
*/ |
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 { ProductRepository as MedusaProductRepository } from "@medusajs/medusa/dist/repositories/product"; | |
import { Repository as MedusaRepository, Utils } from "medusa-extender"; | |
import { EntityRepository, In } from "typeorm"; | |
import { Product } from "./product.entity"; | |
@MedusaRepository({ override: MedusaProductRepository }) | |
@EntityRepository(Product) | |
export default class ProductRepository extends Utils.repositoryMixin<Product, MedusaProductRepository>(MedusaProductRepository) { | |
public async bulkAddToSet( | |
productIds: string[], |
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
#!/usr/bin/env bash | |
############################################################ | |
# Help # | |
############################################################ | |
Help() | |
{ | |
# Display Help | |
echo "Increment the latest tag and create a new tag & release." | |
echo |
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
// Swap two variables, set to integers, | |
// without using a third variable. | |
// Any language you want, but no Assembly. | |
// Register swaps are cheating for | |
// this riddle. | |
let x = 3 | |
let y = 5 | |
console.log(x, y) |
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
var docRef = app.activeDocument; | |
var dialog = new Window("dialog"); | |
dialog.text = "Escolha Cilindro"; | |
dialog.preferredSize.width = 400; | |
dialog.orientation = "column"; | |
dialog.alignChildren = ["left", "top"]; | |
dialog.spacing = 10; | |
dialog.margins = 16; |
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
# System Preferences -> Accessibility -> Display -> Reduce motion | |
tell application "Messages" to activate | |
tell application "Messages" | |
set chatCount to (count of chats) | |
end tell | |
tell application "System Events" | |
tell process "Messages" |
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
/** | |
* Name that script. | |
*/ | |
#script "Contact Sheet"; | |
#target Illustrator | |
var originalInteractionLevel = userInteractionLevel; | |
userInteractionLevel = UserInteractionLevel.DONTDISPLAYALERTS; |
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
#!/usr/bin/env bash | |
# Replace the text PATH_TO_YOUR_DROPBOX_FOLDER with the path to your Dropbox folder (e.g. /home/user/Dropbox) | |
DROPBOX_FOLDER="PATH_TO_YOUR_DROPBOX_FOLDER" | |
# DO NOT CHANGE ANYTHING BELOW THIS LINE | |
# ====================================== | |
PDF_MERGE_WORK_FOLDER="$HOME/pdfmerge" |