Last active
November 27, 2016 06:17
-
-
Save ptiringo/707cc57ab1bf80442b5316c4c4cbcdb6 to your computer and use it in GitHub Desktop.
「送る」with PowerShell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ErrorActionPrefence = "Stop" | |
Set-StrictMode -Version 2.0 | |
$baseDir = $args[0] # ショートカットのリンク先で指定する送り先ディレクトリ | |
$destDir = Join-Path $baseDir "$(Get-Date -Format yyyyMMdd)_$((Get-Item $args[1]).BaseName)" | |
New-Item $destDir -ItemType Directory | |
Move-Item -Path $args[1..$args.Length] -Destination $destDir |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment