^([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+)?$
- Semantic versioning http://semver.org/
- Source of the regex npm/node-semver#32
#!/usr/bin/env bash | |
set -eou pipefail | |
cd /home/pi | |
git clone https://github.com/popcornmix/omxplayer.git | |
cd omxplayer | |
sudo apt-get update && sudo apt install -y git libasound2-dev libva2 libpcre3-dev libidn11-dev libboost-dev libdbus-1-dev libssh-dev libsmbclient-dev libssl-dev | |
# see https://github.com/popcornmix/omxplayer/issues/731 |
@echo off | |
REM We need to delay expansion, otherwise variables inside 'for' block will get replaced when the batch processor reads them in the 'for' loop, before it is executed. | |
REM See this link for details: https://stackoverflow.com/questions/5615206/windows-batch-files-setting-variable-in-for-loop | |
setlocal enabledelayedexpansion | |
REM Iterate over all git repositories | |
for /f %%l in ('find . -name ".git"') do ( | |
echo Checking dir:%%~dpnl |
local function tab2space(filename) | |
local lines = {} | |
io.input(filename) | |
for line in io.lines() do | |
table.insert(lines, line) | |
end | |
local newLine = {} | |
for _, line in ipairs(lines) do |
^([0-9]+)\.([0-9]+)\.([0-9]+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+[0-9A-Za-z-]+)?$
wget -c --no-cookies --no-check-certificate --header "Cookie: oraclelicense=accept-securebackup-cookie" https://download.oracle.com/otn-pub/java/jdk/12.0.2+10/e482c34c86bd4bf8b56c0b35558996b9/jdk-12.0.2_linux-x64_bin.tar.gz |
<NotepadPlus> | |
<UserLang name="Groovy" ext="groovy" udlVersion="2.1"> | |
<Settings> | |
<Global caseIgnored="no" allowFoldOfComments="yes" foldCompact="no" forcePureLC="0" decimalSeparator="0" /> | |
<Prefix Keywords1="no" Keywords2="no" Keywords3="no" Keywords4="no" Keywords5="no" Keywords6="no" Keywords7="no" Keywords8="no" /> | |
</Settings> | |
<KeywordLists> | |
<Keywords name="Comments">03/* 04*/ 00// 01 02</Keywords> | |
<Keywords name="Numbers, prefix1"></Keywords> | |
<Keywords name="Numbers, prefix2"></Keywords> |
set filepath="C:\some path\having spaces.txt" | |
for /F "delims=" %%i in (%filepath%) do set dirname="%%~dpi" | |
for /F "delims=" %%i in (%filepath%) do set filename="%%~nxi" | |
for /F "delims=" %%i in (%filepath%) do set basename="%%~ni" | |
echo %dirname% | |
echo %filename% | |
echo %basename% |
[DllImport("user32.dll", ExactSpelling = true, CharSet = CharSet.Auto)] | |
static extern IntPtr GetParent(IntPtr hWnd); | |
[DllImport("user32", CharSet = CharSet.Auto, SetLastError = true)] | |
static extern int GetWindowText(IntPtr hWnd, [Out, MarshalAs(UnmanagedType.LPTStr)] StringBuilder lpString, int nMaxCount); | |
public static String GetWindowTitle(IntPtr handle) { | |
IntPtr windowParent = IntPtr.Zero; | |
while (handle != IntPtr.Zero) { |
<NotepadPlus> | |
<UserLang name="Groovy" ext="groovy"> | |
<Settings> | |
<Global caseIgnored="no" /> | |
<TreatAsSymbol comment="yes" commentLine="yes" /> | |
<Prefix words1="no" words2="no" words3="no" words4="no" /> | |
</Settings> | |
<KeywordLists> | |
<Keywords name="Delimiters">"'0"'0</Keywords> | |
<Keywords name="Folder+"></Keywords> |
package test; | |
import java.lang.reflect.Method; | |
import java.lang.reflect.Modifier; | |
import java.util.Arrays; | |
import java.util.function.Function; | |
import static java.util.stream.Stream.of; | |
public class FindParametersTypes { |