^([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
| #!/bin/bash | |
| # Usage | |
| ## chmod +x ip_change.sh | |
| ## sudo ./ip_change.sh new_ip | |
| path="/etc/network/interfaces" | |
| current="$(hostname -I | cut -d' ' -f1 | xargs)" | |
| new_ip=$1 |
| #!/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> |
| -- Tested with | |
| -- NodeMCU 3.0.0.0 built on nodemcu-build.com provided by frightanic.com | |
| -- branch: release | |
| -- commit: d4ae3c364bd8ae3ded8b77d35745b7f07879f5f9 | |
| -- release: | |
| -- release DTS: 202105102018 | |
| -- SSL: false | |
| -- build type: float | |
| -- LFS: 0x0 bytes total capacity | |
| -- modules: bit,file,gpio,net,node,spi,tmr,uart,ucg,wifi |
| 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) { |