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
https://support.apple.com/en-us/HT213772 | |
Published Date: November 15, 2023 | |
Verification: https://regex101.com/r/GCfKMt/9 | |
1) Exact regex — Matches major model identifier numbers based on Apple's knowledge base article (more accurate): | |
^(Mac(1[345]|BookPro1[5-8]|BookAir([89]|10)|Pro7)|iMac(Pro1|(19|2[01]))|Macmini[89]),\d+$ | |
2) Current or higher regex — Matches model identifiers based on Apple's knowledge base article and may match higher versions before this regex is updated (more future-proof). |
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 datetime | |
import json | |
import os.path | |
import requests | |
# TO DO: Enter Your BC Account ID | |
# Example: 999999999 from https://3.basecamp.com/999999999/ | |
BC_ACCOUNT_ID = "<your-client-id>" | |
# Basecamp App Integration Information |
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/ruby | |
# Script to add a custom domain to a preview environment web service. Use it via the buildCommand | |
# | |
# Resultant custom domain added to the service will be: | |
# <servicename>-pr-<number>.prs.mydomain.com | |
# | |
# Setup: | |
# | |
# Add a wildcard DNS entry to your domain, something like *.prs.mydomain.com pointing to 216.57.24.1 |
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
#!/bin/sh | |
# Set the icons and branding | |
selfServiceBrandIcon="/Users/$3/Library/Application Support/com.jamfsoftware.selfservice.mac/Documents/Images/brandingimage.png" | |
fileVaultIcon="/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/FileVaultIcon.icns" | |
if [[ -f $selfServiceBrandIcon ]]; then | |
brandIcon="$selfServiceBrandIcon" | |
else | |
brandIcon="$fileVaultIcon" |
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
extension Image { | |
/** | |
``` | |
Image(nsImageNamed: NSImage.addTemplateName) | |
``` | |
- Note: The `size` parameter is there as resizing in SwiftUI creates a blurry image. Seems like a bug: | |
``` | |
Image(nsImageNamed: NSImage.addTemplateName) |
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
export function reduceToParams(elements) { | |
return elements.reduce((hash, node) => Object.assign(hash, { [node.name]: node.value }), {}) | |
} | |
export function stopEverything(e) { | |
e.preventDefault() | |
e.stopPropagation() | |
e.stopImmediatePropagation() | |
} |
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
// DISCLAIMER : You can now probably use `data-turbo-action="advance"` on your frame to perform what this controller is aiming to do | |
// https://turbo.hotwired.dev/handbook/frames#promoting-a-frame-navigation-to-a-page-visit | |
// Note that you probably want to disable turbo cache as well for those page to make popstate work properly | |
import { navigator } from '@hotwired/turbo' | |
import { Controller } from '@hotwired/stimulus' | |
import { useMutation } from 'stimulus-use' | |
export default class extends Controller { | |
connect (): void { |
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
export function transitionIn (el, show = () => {}) { | |
const attrs = getXAttrs(el, 'transition') | |
// If any transition attrs. | |
if (attrs.filter(attr => ['enter', 'enter-start', 'enter-end'].includes(attr.value)).length > 0) { | |
transitionClassesIn(el, attrs, show) | |
} else { | |
// If not, just show that damn thing. | |
show() | |
} |
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
Model information: https://support.apple.com/en-us/HT211238 | |
Published Date: October 25, 2021 | |
Verification: https://regex101.com/r/7nnq4T/13 | |
This regex is complete. Apple is no longer creating Big Sur compatible Macs. | |
(MacBook(10|9|8)|MacBookAir(10|[6-9])|MacBookPro1[1-7]|Macmini[7-9]|MacPro[6-7]|iMacPro1),\d|iMac(14,4|1[5-9],\d|2[01],\d) | |
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
module Entry::TrackerBlocking | |
extend ActiveSupport::Concern | |
included do | |
has_many :blocked_trackers | |
end | |
email_service_blockers = { | |
"ActiveCampaign" => /lt\.php(.*)?l\=open/, | |
"AWeber" => "openrate.aweber.com", |
NewerOlder