Systemd has its own logging system called the journal, and the log files are stored in /var/log/journal.
sudo journalctl --disk-usage- Active journal files will be marked as archived, so that they are never written to in future.
Systemd has its own logging system called the journal, and the log files are stored in /var/log/journal.
sudo journalctl --disk-usage| <?php | |
| /** | |
| * Config for PHP-CS-Fixer ver2 | |
| */ | |
| $rules = [ | |
| '@PSR2' => true, | |
| // addtional rules |
Laravel Homestead is an official, pre-packaged Vagrant box that provides you a wonderful development environment without requiring you to install PHP, HHVM, a web server, and any other server software on your local machine. Read more...
Download homestead box:
| <?php | |
| namespace App\Traits; | |
| use Exception; | |
| use Illuminate\Database\Eloquent\Builder; | |
| /** | |
| * Use this trait if your model has a composite primary key. | |
| * The primary key should then be an array with all applicable columns. |
| <?php | |
| $finder = Symfony\Component\Finder\Finder::create() | |
| ->notPath('bootstrap/cache') | |
| ->notPath('storage') | |
| ->notPath('vendor') | |
| ->in(__DIR__) | |
| ->name('*.php') | |
| ->notName('*.blade.php') | |
| ->ignoreDotFiles(true) |
| #!/usr/bin/env bash | |
| # Ubuntu Server or VM Cleaner. Safe by default; aggressive when asked. | |
| # Example safe: sudo ./clean.sh | |
| # Example aggressive: sudo JOURNAL_DAYS=3 AGGRESSIVE=1 ./clean.sh | |
| # Enable Docker image prune (images only): sudo ./clean.sh --docker-images | |
| # Tested on Ubuntu 20.04, 22.04, 24.04 (server/VM images). | |
| set -Eeuo pipefail | |
| trap 'rc=$?; echo "Error on line $LINENO: $BASH_COMMAND (exit $rc)"; exit $rc' ERR | |
| IFS=$'\n\t' |
| // Reference: http://www.blackdogfoundry.com/blog/moving-repository-from-bitbucket-to-github/ | |
| // See also: http://www.paulund.co.uk/change-url-of-git-repository | |
| $ cd $HOME/Code/repo-directory | |
| $ git remote rename origin bitbucket | |
| $ git remote add origin https://github.com/mandiwise/awesome-new-repo.git | |
| $ git push origin master | |
| $ git remote rm bitbucket |
Saya support Internet Positif untuk memblokir porn, situs judi, dan hal-hal ilegal lainnya. Tapi pemerintah dan ISP sangat konyol karena tidak mengizinkan akses ke Vimeo, Reddit, Imgur, Netflix--yang mana bukanlah situs dengan konten utama ilegal.
Tambahkan list di bawah ke /etc/hosts.
| #!/bin/bash | |
| # Usage: ./deleteOld "bucketname" "30 days" | |
| s3cmd ls s3://$1 | while read -r line; | |
| do | |
| createDate=`echo $line|awk {'print $1" "$2'}` | |
| createDate=`date -d"$createDate" +%s` | |
| olderThan=`date -d"-$2" +%s` | |
| if [[ $createDate -lt $olderThan ]] |
| #!/bin/sh | |
| # Converts a mysqldump file into a Sqlite 3 compatible file. It also extracts the MySQL `KEY xxxxx` from the | |
| # CREATE block and create them in separate commands _after_ all the INSERTs. | |
| # Awk is choosen because it's fast and portable. You can use gawk, original awk or even the lightning fast mawk. | |
| # The mysqldump file is traversed only once. | |
| # Usage: $ ./mysql2sqlite mysqldump-opts db-name | sqlite3 database.sqlite | |
| # Example: $ ./mysql2sqlite --no-data -u root -pMySecretPassWord myDbase | sqlite3 database.sqlite |