$ docker
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
#!/usr/bin/env bash | |
if [ "$EUID" -ne 0 ];then | |
>&2 echo "This script requires root level access to run" | |
exit 1 | |
fi | |
if [ -z "${WORDPRESS_DB_PASSWORD}" ]; then | |
>&2 echo "WORDPRESS_DB_PASSWORD must be set" | |
>&2 echo "Here is a random one that you can paste:" |
This will get you setup with Laravel & Valet on your Mac. Quentin Watt has a good video tutorial on getting setup here as well
Go to https://brew.sh/ and copy the command and run in your terminal
It will be something like this...
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
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
class LoginViewController: UIViewController { | |
// lots of code removed. | |
@objc func buttonAction() { | |
let windowScene = view.window?.windowScene | |
let sceneDelegate = windowScene?.delegate as! SceneDelegate | |
sceneDelegate.loadTabBarController(). |
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 UIKit | |
import WebKit | |
class DetailViewController: UIViewController, WKNavigationDelegate { | |
var articleURLString: String! | |
let webView = WKWebView() | |
override func loadView() { | |
self.view = webView |
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
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) { | |
if let cell = collectionView.cellForItem(at: indexPath) as? ClinicianViewCell { | |
let clinician = clinicians[indexPath.item] | |
UIView.animate(withDuration: 0.1, delay: 0, options: [], animations: { [weak self] in | |
cell.transform = CGAffineTransform(scaleX: 0.95, y: 0.95) | |
cell.clinicianState.transform = CGAffineTransform(scaleX: 1, y: -1) | |
cell.photoImageView.transform = CGAffineTransform(translationX: -3, y: 3) |
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
class NewViewController: UIViewController { | |
@IBOutlet var webView: WKWebView! | |
var fileToLoad: URL? | |
override func loadView() { | |
webView = WKWebView() | |
self.view = webView | |
} |
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
// | |
// OnboardingController.swift | |
// Onboarding | |
import UIKit | |
class OnboardingController: UICollectionViewController, UICollectionViewDelegateFlowLayout { | |
override func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator) { | |
super.viewWillTransition(to: size, with: coordinator) |
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
// get xml file & publish | |
km.core = { | |
url: 'someDir/someFile', | |
fetch: $.get(url, function(xml) { | |
$.publish('xmlFetch', [xml]); | |
}) | |
}; | |
// subscribe to xml file and do stuff | |
km.widget.edVolGraph = { |
NewerOlder