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 | |
$filename = 'in.csv'; | |
$outDir = 'out'; | |
$in = fopen($filename, 'r'); | |
$out = []; | |
$outName = pathinfo($filename, PATHINFO_FILENAME) . '_'; | |
$extension = pathinfo($filename, PATHINFO_EXTENSION); |
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 | |
$files = glob('ent_*.log'); | |
echo 'Найдены логи:', PHP_EOL; | |
$inputs = array_map(function ($filepath) { | |
echo '- ', $filepath, PHP_EOL; | |
return fopen($filepath, 'r'); | |
}, $files); |
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 | |
// Название столбца, по значению которого нужно разбивать файлы | |
$splitColumn = 'Источник'; | |
// Название входного файла | |
$filename = 'in.csv'; | |
// Папка, в которую будут сохранятся файлы | |
$outDir = 'out'; |
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 | |
# Переменные | |
## Основные | |
### Имя пользователя MySQL | |
user=backup | |
### Пароль пользователя MySQL | |
password=backup | |
### Путь к папке (относительно скрипта), в которой сохранится бекап | |
storage=$(pwd -P)/db_backup |
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 | |
if [ ! -n "$1" ]; | |
then | |
echo Вы должны ввести путь к папке; | |
exit 1; | |
fi; | |
folder=$(readlink -f $1); | |
shift; |
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
Computer Information: | |
Manufacturer: Unknown | |
Model: Unknown | |
Form Factor: Desktop | |
No Touch Input Detected | |
Processor Information: | |
CPU Vendor: GenuineIntel | |
CPU Brand: Intel(R) Core(TM)2 Duo CPU E7400 @ 2.80GHz | |
CPU Family: 0x6 |
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 | |
# Менять порядок строк не рекомендуется! | |
ssh_dir=~/.ssh | |
find $ssh_dir -name "*_*" -exec chmod 600 {} \; | |
find $ssh_dir -name "*_*.pub" -exec chmod 644 {} \; | |
chmod 644 $ssh_dir/authorized_keys $ssh_dir/known_hosts $ssh_dir/config | |
chmod 700 $ssh_dir |
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
struct stBulletData | |
{ | |
uint8_t byteType; | |
uint16_t sTargetID; | |
float fOrigin[3]; | |
float fTarget[3]; | |
float fCenter[3]; | |
uint8_t byteWeaponID; | |
}; |