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
Starting Named Session | |
Named sessions are useful when you run multiple screen sessions. To create a named session, run the screen command with the following arguments: | |
screen -S session_name | |
It’s always a good idea to choose a descriptive session name. | |
Working with Linux Screen Windows | |
When you start a new screen session, it creates a single window with a shell in it. |
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 | |
# | |
# Резервное копирование каталогов и файлов из домашнего каталога | |
# Этот командный скрипт можно автоматически запускать при помощи cron | |
# | |
DATE=`date +%F` # This Command will add date in Backup File Name. | |
TIME=`date +%H-%M-%S` # This Command will add time in Backup File Name. | |
COMPNAME=EB | |
DESDIR=/home/anwas/clouds/nextCloud-eb/personal-share/backups_srv # Destination of backup file. |
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
git init | |
git add . | |
git commit -a -m "Initial commit" | |
git tag -a 1.0.0 | |
git tag -n | |
git checkout -b develop master | |
git checkout -b feature-clean-footer develop | |
git checkout develop |
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
## Add repository | |
### https://launchpad.net/%7Eondrej/+archive/ubuntu/php | |
### https://launchpad.net/~ondrej/+archive/ubuntu/apache2 | |
sudo add-apt-repository ppa:ondrej/php | |
sudo add-apt-repository ppa:ondrej/apache2 | |
sudo apt-get update | |
sudo apt-get dist-upgrade | |
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
<?php | |
// Patern http://userguide.icu-project.org/formatparse/datetime | |
// Patern http://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table | |
$fmt = new IntlDateFormatter('lt_LT', IntlDateFormatter::FULL, | |
IntlDateFormatter::NONE, 'Europe/Vilnius', IntlDateFormatter::GREGORIAN, "cccc"); | |
$timestamp = strtotime('now'); | |
$timestamp = strtotime('today'); | |
$timestamp = strtotime('+7 days'); | |
$timestamp = strtotime('next day'); | |
echo datefmt_format( $fmt , time() ); |
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
.grid-gallery { | |
padding: 0.5rem; | |
} | |
.grid-gallery-item { | |
padding: 0; | |
margin: 0.5rem; | |
max-width: 200px; | |
display: inline-block; | |
} |
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
<?php | |
/* | |
* Include Custom Templates | |
*************************************************************************** */ | |
function my_custom_template( $template ) { | |
// patikrinama ar rodomas puslapis yra pasirinktinio tipo įrašų archyvas | |
if ( ! is_admin() && is_post_type_archive( 'custom-post-type' ) ) { | |
// įtraukiami reikiami stiliai ir scenarijai | |
add_action( 'wp_enqueue_scripts', 'my_custom_styles' ); | |
add_action( 'wp_enqueue_scripts', 'my_custom_scripts' ); |