Some things you need :
- Laravel project
- VPS / Virtual Private Server
- Domain (if any)
- Put your Laravel project into source code management (github/gitlab/others)
Here I will use my company-management reporsitory.
Some things you need :
| /** | |
| * Bootstrap any application services. | |
| * | |
| * @return void | |
| */ | |
| public function boot() | |
| { | |
| Component::macro('notify', function ($message, $title = '', $type = 'success') { | |
| $this->dispatchBrowserEvent('notify', ['message' => $message, 'title' => $title, 'type' => $type]); | |
| }); |
| class CompanyView extends GetView<CompanyController> { | |
| @override | |
| Widget build(BuildContext context) { | |
| return Scaffold( | |
| body: Stack( | |
| children: [ | |
| Container( | |
| child: Column( | |
| crossAxisAlignment: CrossAxisAlignment.start, | |
| children: [ |
| Add middleware: | |
| ... | |
| 'mynova' => [ | |
| 'web', | |
| Authenticate::class, | |
| DispatchServingNovaEvent::class, | |
| BootTools::class, | |
| Authorize::class, | |
| ] |
| { | |
| // Place your snippets for dart here. Each snippet is defined under a snippet name and has a prefix, body and | |
| // description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are: | |
| // $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the | |
| // same ids are connected. | |
| // Example: | |
| // "Print to console": { | |
| // "prefix": "log", | |
| // "body": [ | |
| // "console.log('$1');", |
public static function boot() {
parent::boot();
// Trim all string attributes before they are saved
static::saving(function($model){
$attributes = collect($model->getAttributes())->map(function ($attribute) {
if (is_string($attribute)) {
return trim($attribute);
}| # Some youtube-dl shortcuts and workarounds. | |
| # Download MP3 | |
| alias youtube-dl-mp3="youtube-dl --extract-audio --audio-format mp3 " | |
| # Youtube playlist which is organised in folders and Videos are numbered. | |
| # use youtube-dl-playlist -f 22 <link> | |
| alias youtube-dl-playlist='youtube-dl -o "./%(playlist_title)s/%(playlist_index)s_%(title)s.%(ext)s" ' | |
| # Youtube-dl to download from hotstar. |
| <?xml version="1.0" encoding="utf-8"?> | |
| <!-- The android:opacity=”opaque” line — this is critical in preventing a flash of black as your theme transitions. --> | |
| <layer-list xmlns:android="http://schemas.android.com/apk/res/android" android:opacity="opaque"> | |
| <!-- The background color, preferably the same as your normal theme --> | |
| <item android:drawable="@android:color/white"/> | |
| <!-- Your product logo - 144dp color version of your app icon --> | |
| <item> |
| { | |
| "additional_path_items": | |
| [ | |
| "/usr/local/php5/bin/" | |
| ], | |
| "auto_complete_selector": "source, text", | |
| "bold_folder_labels": true, | |
| "color_scheme": "Packages/Colorsublime-Themes/Facebook.tmTheme", | |
| "font_face": "Fira Code", | |
| "font_options": [], |
| [ | |
| "United States" => "us", | |
| "Afghanistan" => "af", | |
| "Albania" => "al", | |
| "Algeria" => "dz", | |
| "American Samoa" => "as", | |
| "Andorra" => "ad", | |
| "Angola" => "ad", | |
| "Anguilla" => "ai", | |
| "Antarctica" => "aq", |