To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.
- Homebrew
- Mountain Lion -> High Sierra
To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.
| module RailsAdmin | |
| module PostConfig | |
| def self.extended(base) | |
| base.class_eval do | |
| rails_admin do | |
| weight -10 | |
| list(&base.rails_admin_list_fields) | |
| edit(&base.rails_admin_edit_fields) |
| #!/bin/bash | |
| # | |
| # This pre-commit hook checks that you havn't left and DONOTCOMMIT tokens in | |
| # your code when you go to commit. | |
| # | |
| # To use this script copy it to .git/hooks/pre-commit and make it executable. | |
| # | |
| # This is provided just as an example of how to use a pre-commit hook to | |
| # catch nasties in your code. |
| #!/bin/sh | |
| # /share/CE_CACHEDEV1_DATA/.qpkg/autorun/autorun-plexconnect.sh | |
| # | |
| # mkdir /share/CE_CACHEDEV1_DATA/.qpkg/autorun | |
| # chmod +x /share/CE_CACHEDEV1_DATA/.qpkg/autorun/autorun-plexconnect.sh | |
| curl -Lk https://gist.githubusercontent.com/plasticine/86e189c42ac8ec7598a8/raw/update_plex_connect.sh | bash & |
| import Ember from "ember"; | |
| const AUTO_EMAIL_RE = /([\w.!#\$%+-]+@[\w-]+(?:\.[\w-]+)+)/; | |
| const AUTO_LINK_CRE = [/<[^>]+$/, /^[^>]*>/]; | |
| const AUTO_LINK_RE = /(?:((?:ed2k|ftp|http|https|irc|mailto|news|gopher|nntp|telnet|webcal|xmpp|callto|feed|svn|urn|aim|rsync|tag|ssh|sftp|rtsp|afs|file):)\/\/|(www\.))([^\s<]+)/; | |
| var autoLink = function (text, context) { | |
| var buffer = []; | |
| if (context.autoLink) { |
| // tests/acceptance/foo-test.js | |
| // Assert that text should be found | |
| assert.hasText('Not Found'); // Error: Could not find text "Not Found" on the page | |
| // Provide custom message | |
| assert.hasText('Not Found', 'Expected to find "Not Found"'); // Error: Expected to find "Not Found" | |
| // Find any number of elements containing the query text | |
| text('Found'); // [<div>Found</div>, <input value="Found">] |
| class Hash | |
| def dig(*path) | |
| path.inject(self) do |location, key| | |
| location.is_a?(Hash) ? location[key] : nil | |
| end | |
| end | |
| end |
| # Tutorial https://www.daimto.com/how-to-get-a-google-access-token-with-curl/ | |
| # YouTube video https://youtu.be/hBC_tVJIx5w | |
| # Client id from Google Developer console | |
| # Client Secret from Google Developer console | |
| # Scope this is a space seprated list of the scopes of access you are requesting. | |
| # Authorization link. Place this in a browser and copy the code that is returned after you accept the scopes. | |
| https://accounts.google.com/o/oauth2/auth?client_id=[Application Client Id]&redirect_uri=http://127.0.0.1&scope=[Scopes]&response_type=code | |
| # Exchange Authorization code for an access token and a refresh token. |