https://intl.aliyun.com/help/doc-detail/25426.htm
View the disks
fdisk -l
Run the following command to partition the data disk.
| /* | |
| * Licensed to the Apache Software Foundation (ASF) under one | |
| * or more contributor license agreements. See the NOTICE file | |
| * distributed with this work for additional information | |
| * regarding copyright ownership. The ASF licenses this file | |
| * to you under the Apache License, Version 2.0 (the | |
| * "License"); you may not use this file except in compliance | |
| * with the License. You may obtain a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| @echo off | |
| REM usage: for /f "delims=" %%a in ('yesterday.bat') do @set YESTERDAY=%%a | |
| setlocal | |
| set yyyy= | |
| set $tok=1-3 | |
| for /f "tokens=1 delims=.:/-, " %%u in ('date /t') do set $d1=%%u |
| @echo off | |
| REM usage: for /f "delims=" %%a in ('today.bat') do @set TODAY=%%a | |
| setlocal | |
| set yyyy= | |
| set $tok=1-3 | |
| for /f "tokens=1 delims=.:/-, " %%u in ('date /t') do set $d1=%%u |
| @echo off | |
| REM usage: for /f "delims=" %%a in ('lastmonth.bat') do @set LASTMONTH=%%a | |
| REM usage: for /f "delims=" %%a in ('lastmonth.bat YYYYMM') do @set LASTMONTH=%%a | |
| setlocal | |
| set yyyy= | |
| set $tok=1-3 |
| import java.util.HashMap; | |
| import java.util.Map; | |
| import com.google.gson.Gson; | |
| import com.google.gson.GsonBuilder; | |
| /** | |
| * https://repo1.maven.org/maven2/com/google/code/gson/gson/2.8.0/ | |
| * <p> | |
| * Output: |
| import java.io.BufferedReader; | |
| import java.io.FileReader; | |
| import java.io.IOException; | |
| import java.util.regex.Matcher; | |
| import java.util.regex.Pattern; | |
| import com.eaio.stringsearch.BNDMWildcards; | |
| import com.eaio.stringsearch.BoyerMooreHorspool; | |
| import com.eaio.stringsearch.BoyerMooreHorspoolRaita; | |
| import com.eaio.stringsearch.StringSearch; |
| #!/usr/bin/env groovy | |
| def xml = new XmlSlurper().parseText(new File(this.args.length>0?this.args[0]:"pom.xml").getText("UTF-8")); | |
| println "${xml.groupId}/${xml.artifactId}:${xml.version}" | |
| xml.dependencies.dependency.each() { dep -> | |
| println " ${dep.groupId}/${dep.artifactId}:${dep.version}" | |
| } |
| export DEVLIB_HOME=/cygdrive/d/devlib | |
| export APP_HOME=/cygdrive/d/apps | |
| # PATH | |
| export PATH=/usr/bin:$PATH | |
| export PATH=$APP_HOME/tools/:/cygdrive/c/Program\ Files/cvsnt:$PATH | |
| # Java | |
| export JAVA13_HOME=$DEVLIB_HOME/jdk1.3.1_09 | |
| export JAVA14_HOME=$DEVLIB_HOME/j2sdk1.4.2_10 |
https://intl.aliyun.com/help/doc-detail/25426.htm
View the disks
fdisk -l
Run the following command to partition the data disk.
| WITH cal AS (SELECT TRUNC(TO_DATE('20170505', 'YYYYMMDD')) + ROWNUM - 1 dt FROM DUAL CONNECT BY LEVEL < 13) | |
| SELECT dt as TODAY, | |
| 1 + TRUNC(dt - 1) - TRUNC(dt, 'iw') AS dow, | |
| TO_CHAR(dt, 'DY') AS dow_name, | |
| dt - GREATEST((1 + TRUNC (dt) - TRUNC (dt, 'iw')) - 5, 0) AS last_working_date, | |
| dt - 1 as YESTERDAY, | |
| dt - 1 - GREATEST((1 + TRUNC (dt - 1) - TRUNC (dt - 1, 'iw')) - 5, 0) AS last_working_date_of_yesterday | |
| FROM cal; | |
| select trunc(sysdate-GREATEST((1+TRUNC(sysdate)-TRUNC(sysdate, 'iw'))-5, 0)) from dual; |