- Exclude dirs:
.git|node_modules|vendor|storage|framework7|laravel-framework|cache|database|third_party|wedding
- File Names match:
*.ahk|*env*|*.js|*.md|*.php*|*css|*.xml|*.html|*.json|artisan|*.vue|*config|*access|*.bat|*.yml|*.ics|*.csv|*.xml|*.log|-*lock.*|*.svg|*.yaml|*.ini|*.tpl
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
[CmdletBinding()] Param ( | |
[Parameter()][ValidateSet('On', 'Off')][string]$BluetoothStatus | |
) | |
If ((Get-Service bthserv).Status -eq 'Stopped') { Start-Service bthserv } | |
Add-Type -AssemblyName System.Runtime.WindowsRuntime | |
$asTaskGeneric = ([System.WindowsRuntimeSystemExtensions].GetMethods() | ? { $_.Name -eq 'AsTask' -and $_.GetParameters().Count -eq 1 -and $_.GetParameters()[0].ParameterType.Name -eq 'IAsyncOperation`1' })[0] | |
Function Await($WinRtTask, $ResultType) { | |
$asTask = $asTaskGeneric.MakeGenericMethod($ResultType) | |
$netTask = $asTask.Invoke($null, @($WinRtTask)) | |
$netTask.Wait(-1) | Out-Null |
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
@echo off | |
:: Clear Microsoft version notice displayed by an | |
:: Administrator CMD & shells opened by Fork | |
cls | |
:: Enable unicode support | |
chcp 65001 >NUL | |
if exist .\laravel cd laravel |
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 | |
declare(strict_types=1); | |
use Rector\Core\Configuration\Option; | |
use Rector\Core\ValueObject\PhpVersion; | |
use Rector\Php53\Rector\Ternary\TernaryToElvisRector; | |
use Rector\Set\ValueObject\SetList; | |
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator; |
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
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
<IfModule mod_env.c> | |
# Scheduled Maintenance | |
RewriteRule ^ - [E=MAINTENANCE_DATE:False] | |
RewriteCond %{TIME_YEAR}%{TIME_MON}%{TIME_DAY} 20230509 [OR] | |
RewriteCond %{TIME_YEAR}%{TIME_MON}%{TIME_DAY} 20230523 [OR] | |
RewriteCond %{TIME_YEAR}%{TIME_MON}%{TIME_DAY} 20230613 [OR] | |
RewriteCond %{TIME_YEAR}%{TIME_MON}%{TIME_DAY} 20230627 [OR] |
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
block-closing-brace-empty-line-before | |
block-closing-brace-newline-after | |
block-closing-brace-newline-before | |
block-closing-brace-space-after | |
block-closing-brace-space-before | |
block-opening-brace-newline-after | |
block-opening-brace-newline-before | |
block-opening-brace-space-after | |
block-opening-brace-space-before | |
color-hex-case |
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 | |
function session_readonly(){ | |
if(version_compare(PHP_VERSION, '7.0.0') >= 0){ | |
session_start(array('read_and_close' => true)); | |
} else { | |
$session_name = preg_replace('/[^\da-z]/i', '', $_COOKIE[session_name()]); | |
$session_data = file_get_contents(session_save_path() . '/sess_' . $session_name); | |
$return_data = array(); | |
$offset = 0; |
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
function RGBtoRGBA(r, g, b){ | |
if((g==void 0) && (typeof r == 'string')){ | |
r = r.replace(/^\s*#|\s*$/g, ''); | |
if(r.length == 3){ | |
r = r.replace(/(.)/g, '$1$1'); | |
} | |
g = parseInt(r.substr(2, 2), 16); | |
b = parseInt(r.substr(4, 2), 16); | |
r = parseInt(r.substr(0, 2), 16); | |
} |
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
@ECHO off | |
FOR /F "tokens=2" %%K IN (' | |
tasklist /FI "ImageName eq notepad++.exe" /FI "Status eq Not Responding" /FO LIST ^| findstr /B "PID:" | |
') DO ( | |
:: Check for number | |
SET "var="&for /f "delims=0123456789" %%i in ("%%K") do set var=%%i | |
IF NOT DEFINED var ( | |
:: https://processhacker.sourceforge.io/ |
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
function isNumeric(n) { | |
return !isNaN(parseFloat(n)) && isFinite(n); | |
} |
NewerOlder