Skip to content

Instantly share code, notes, and snippets.

View victorwoo's full-sized avatar

victorwoo victorwoo

View GitHub Profile
@victorwoo
victorwoo / PowerShell 检测是否以管理员身份运行.ps1
Created July 26, 2019 01:13
Gist-PowerShell 检测是否以管理员身份运行
([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]"Administrator")
@victorwoo
victorwoo / EditorServices.log
Last active September 3, 2018 08:15
Visual Studio Code PowerShell Extension crashes when IntelliSense about to pop out on passing param to custom function
2018-09-03 16:00:00.038 [NORMAL] C:\PowerShellEditorServices\src\PowerShellEditorServices.Host\EditorServicesHost.cs: In method 'StartLogging', line 160:
PowerShell Editor Services Host v1.8.4.0 starting (pid 5533)...
Host application details:
Name: Visual Studio Code Host
ProfileId: Microsoft.VSCode
Version: 1.8.4
@victorwoo
victorwoo / index.html
Created April 14, 2015 08:43
input in ion-list
<html ng-app="ionicApp">
<head>
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
<title>Ionic Pull to Refresh</title>
<link href="//code.ionicframework.com/nightly/css/ionic.css" rel="stylesheet">
<script src="//code.ionicframework.com/nightly/js/ionic.bundle.js"></script>
import java.io.UnsupportedEncodingException;
public class TextFormat {
public static void main(String[] args) {
try {
String output = String.format("%s%3s", buildSpanAlignLeft("字符串1", 10), "A");
System.out.print(output);
} catch (UnsupportedEncodingException e) {