|
1 2 3 4 5 |
$(document).on("keydown", function (e) { if (e.which === 8 && !$(e.target).is("input, textarea")) { e.preventDefault(); } }); |
|
1 2 3 4 5 |
$(document).on("keydown", function (e) { if (e.which === 8 && !$(e.target).is("input, textarea")) { e.preventDefault(); } }); |
|
1 2 3 4 5 6 7 8 |
# checkout the root commit git checkout <sha1-of-root> # amend the commit git commit --amend # rebase all the other commits in master onto the amended root git rebase --onto HEAD HEAD master |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
DECLARE FUNCTION NAMED_DAYS_BETWEEN(VP_MIN IN DATE, VP_MAX IN DATE, VP_DAY IN VARCHAR2) RETURN NUMBER IS BEGIN RETURN TRUNC(NEXT_DAY(VP_MAX, VP_DAY) - NEXT_DAY(VP_MIN - 1, VP_DAY)) / 7; END; FUNCTION BUSINESS_DAYS_BETWEEN(VP_MIN IN DATE, VP_MAX IN DATE) RETURN NUMBER IS BEGIN RETURN VP_MAX - VP_MIN -(NAMED_DAYS_BETWEEN(VP_MIN, VP_MAX, 'SAT') + -- German: SA NAMED_DAYS_BETWEEN(VP_MIN, VP_MAX, 'SUN')) + 1; -- German: SO END; BEGIN DBMS_OUTPUT.PUT_LINE('Business Days: ' || BUSINESS_DAYS_BETWEEN(SYSDATE, SYSDATE + 15)); END; |
|
1 |
yum install kernel-uek-devel |
RHEL/Oracle Linux
CentOS
|
1 2 3 4 |
SELECT TO_DATE(TABLE.DATE_FIELD) AS DATE_FIELD FROM TABLE WHERE TABLE.DATE_FIELD > TO_DATE(TABLE.DATE_FIELD) AND TABLE.DATE_FIELD < TO_DATE(TABLE.DATE_FIELD) + NUMTODSINTERVAL('1', 'day') |
|
1 |
watch -n 1 --differences "mysql -u username -pPassword -e 'show processlist'" |
I have a VirtualBox running CentOS 6.4 on a Windows 7 Host System.
I have a directory containing all files for the Webapp on the host system.
This directory is made available as a network share.
The virtual machine mounts the windows share via samba.
After a while i start getting “failed to open stream: Cannot allocate memory / Nicht genügent Hauptspeicher” errors.
The Problem is the windows share. It seems that Windows 7 is not tuned to server large amounts of files frequently.
This can be fixed with those registry tweaks:
|
1 2 |
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management\LargeSystemCache to 1 HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters\Size to 3 |
|
1 2 3 4 5 6 7 |
Windows Registry Editor Version 5.00 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management] "LargeSystemCache"=dword:00000001 [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\LanmanServer\Parameters] "Size"=dword:00000003 |
The JRE keytool must be used to import a self signed ssl certificate.
The self signed ssl certificate must be imported with the PHPStorm JRE.
As the keystore you must use PHPStorm/Path/jre/lib/security/caerts.
The default password is: changeit
|
1 |
C:\Program Files (x86)\JetBrains\PhpStorm 6.0\jre\jre\bin>keytool -import -file c:/certificate.crt -keystore ../lib/security/cacerts |
|
1 |
namei -om /path/to/dir |
|
1 2 3 4 5 6 7 8 9 10 |
namei -om /var/www/mbeck/pwgen.mbeck.org/htdocs/public/index.html f: /var/www/mbeck/pwgen.mbeck.org/htdocs/public/index.html drwxr-xr-x root root / drwxr-xr-x root root var drwxr-xr-x root root www drwxr-x--- mbeck nginx mbeck drwxr-xr-x mbeck mbeck pwgen.mbeck.org drwxr-xr-x mbeck mbeck htdocs drwxr-xr-x mbeck mbeck public -rw-r--r-- mbeck mbeck index.html |