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
@if(!is_null(session('flash_notification'))) | |
@foreach ((array)session('flash_notification') as $message) | |
@php $message = (array)$message[0]; @endphp | |
@javascript([ | |
'Message' => $message | |
]) | |
<script> |
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 | |
# Copy the url of the active ngrok connection to the clipboard. | |
# Usage: | |
# ngrok-copy # copies e.g. https://3cd67858.ngrok.io to clipboard. | |
# ngrok-copy -u # copies e.g. http://3cd67858.ngrok.io to clipboard. | |
if [[ "$1" == "-u" ]]; then | |
NGROK_URL=`curl -s http://127.0.0.1:4040/status | grep -P "http://.*?ngrok.io" -oh` | |
else | |
NGROK_URL=`curl -s http://127.0.0.1:4040/status | grep -P "https://.*?ngrok.io" -oh` |
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
<script src="{{ asset('js/app.js') }}?v={{ filemtime(public_path('js/app.js')) }}"></script> |
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
# | |
# REQUIRES: | |
# - server (the forge server instance) | |
# - event (the forge event instance) | |
# - sudo_password (random password for sudo) | |
# - db_password (random password for database user) | |
# - callback (the callback URL) | |
# |
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
try | |
set theDestinationFolder to ((path to documents folder) as text) & "database_dumps" as alias | |
on error -- the folder doesn't exist | |
return beep 3 | |
end try |
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
public function handle() | |
{ | |
$timings = []; | |
$results = []; | |
$loops = 10; | |
$bar = $this->output->createProgressBar($loops); | |
for($i = 1; $i <= $loops; $i++){ | |
$start = microtime(true); |
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
axios({ | |
url: 'http://localhost/download.pdf', | |
method: 'GET', | |
responseType: 'blob', | |
}).then((response) => { | |
window.location = window.URL.createObjectURL(new Blob([response.data])); | |
}); |
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
" _ _ " | |
" _ /|| . . ||\ _ " | |
" ( } \||D ' ' ' C||/ { % " | |
" | /\__,=_[_] ' . . ' [_]_=,__/\ |" | |
" |_\_ |----| |----| _/_|" | |
" | |/ | | | | \| |" | |
" | /_ | | | | _\ |" | |
It is all fun and games until someone gets hacked! |
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/bash | |
COMMITMSG=`git log -1 --pretty=%B` | |
PARALLEL_TASKS=('cache:clear' 'config:cache' 'route:cache' 'view:cache' 'event:cache' 'opcache:compile') | |
composer install --no-ansi --no-interaction --no-progress --no-dev --prefer-dist --optimize-autoloader --classmap-authoritative -q | |
php artisan deployment:start | |
if [[ $COMMITMSG =~ "SYNC" ]] | |
then | |
php artisan database:sync -C -M |
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 DEBIAN_FRONTEND=noninteractive | |
REMOVABLE_DEPS=('beanstalkd' 'memcached') | |
IMAGEMAGICK_DEPS=('imagemagick' 'pkg-config' 'libmagickwand-dev') | |
MEDIALIBRARY_DEPS=('jpegoptim' 'optipng' 'pngquant' 'gifsicle') | |
WKHTMLTOX_DEPS=('libfontenc1' 'xfonts-75dpi' 'xfonts-base' 'xfonts-encodings' 'xfonts-utils') | |
echo "\e[32mSetting system timezone" | |
sudo timedatectl set-timezone Europe/Amsterdam |
OlderNewer