Asks for admin privileges via macOS security dialog and writes in the /etc/sudoers file this string:
youruser ALL=(ALL) NOPASSWD:ALL
allowing you to execute next sudo commands without asking for password via terminal.
| function NestedScrollViewManager (parent_view) | |
| { | |
| // Appcelerator Titanium code for managing scrollviews inside of scrollviews (not true Android | |
| // NestedScrollViews, but just a horizontal scrollview inside of a vertical scrollview). | |
| // | |
| // If you want to put a horizontal scrollview inside a vertical scrollview (like the Netflix app UI), | |
| // it seems to work reasonably well on iOS. But on android, the user experience is very janky. | |
| // Unless the user's drag movements are nearly exactly horizontal, there will be some movement of | |
| // the parent scrollview, and then it becomes very difficult to scroll the child view. Flinging is | |
| // almost impossible. |
| #!/bin/bash | |
| SERVER_PORT="${1:-8080}" | |
| function handleRequest(){ | |
| # $METHOD = GET|POST | |
| # $FULL_REQUEST = /query/url/complete?with=params | |
| # $REQUEST = /query/url/complete | |
| # render query parameters as QUERY_* environment variables |
| <?php | |
| //creating categories in magento 2 | |
| //last verified Magento 2.2.0 27 Oct 2017 | |
| use \Magento\Framework\App\Bootstrap; | |
| echo 'code by harshvardhanmalpani'; | |
| include('./app/bootstrap.php'); | |
| $bootstrap = Bootstrap::create(BP, $_SERVER); | |
| $objectManager = $bootstrap->getObjectManager(); | |
| function createCategory($a='',$b=2,$c=true,$d='',$e='',$f='',$g='') { | |
| global $objectManager; |
With TOR, you can specify the country of exit nodes to test a particular website from a specific country.
Just add these 4 lines in the torrc file.
ExitNodes {jp}
StrictNodes 1
GeoIPExcludeUnknown 1
AllowSingleHopCircuits 0
Gitlab exports repositories to tar archive which contains .bundle files.
We have repo.bundle file and we want to restore files from it.
git clone --mirror myrepo.bundle my.git
If you're trying to load a private repository with Composer/Laravel, we'll need to generate a GitHub Personal Access Token (similar to OAuth token) to access the repository during a composer install without entering credentials.
If you have used other Github packages from
{my-org}before, you may be able to skip this step.
Click Generate new token.
In general, the command ldd and the environment variable LD_LINKER_PATH is your best friend when running new, untested binaries in Lambda. My process (which I want to get around to automating one day, maybe using Packer), goes like this:
ldd -v ./the-binary. Note all of the shared libraries it requires. You’ll need to remember these.console.log(require('child_process').execSync('ldd -v ./the-binary'))These files show one way to make the next.js "with-global-stylesheet" example work with the amazingly awesome Storybook ecosystem.
Specifically, the three files below replace the next.config.js file, in the "with-global-stylesheet" example.
More generically, they demonstrate how to share webpack configuration extensions between next.js and Storybook.
A massive THANK YOU to tmeasday for all his help to get these working!
| #!/bin/bash | |
| CONTAINER="/var/www/html" | |
| DOMAIN="kopiro.it" | |
| PUBLIC_DIR="$CONTAINER/public" | |
| BACKUP_DIR="$CONTAINER/conf/backup/$(date +%s)" | |
| mkdir -p "$BACKUP_DIR" | |
| cp -v $CONTAINER/conf/*.pem "$BACKUP_DIR/" |