Skip to content

Commit

Permalink
Update cabdir.bat
Browse files Browse the repository at this point in the history
  • Loading branch information
npocmaka authored Mar 9, 2017
1 parent aa30171 commit 014e348
Showing 1 changed file with 20 additions and 10 deletions.
30 changes: 20 additions & 10 deletions hybrids/makecab/cabdir.bat
Original file line number Diff line number Diff line change
@@ -1,20 +1,30 @@
;@echo off

;;;;; rem start of the batch part ;;;;;
; if "%~2" EQU "" (
; echo invalid arguments.For help use:
; echo %~nx0 /h
; exit /b 1
;)
;
;for %%a in (/h /help -h -help) do (
; if "%~1" equ "%%~a" (
; if /I "%~1" equ "%%~a" if "%~2" equ "" (
; echo compressing directory to cab file
; echo %~nx0 directory cabfile
; echo Usage:
; echo(
; echo %~nx0 "directory" "cabfile"
; echo(
; echo to uncompress use:
; echo EXPAND cabfile -F:* .
; echo(
; echo Example:
; echo(
; echo %~nx0 "c:\directory\logs" "logs"
; exit /b 0
; )
; )
;
; if "%~2" EQU "" (
; echo invalid arguments.For help use:
; echo %~nx0 /h
; exit /b 1
;)
;
; set "dir_to_cab=%~f1"
;
; set "path_to_dir=%~pn1"
Expand All @@ -37,17 +47,17 @@
; set "destdir=%dir_name%!_dir:%path_to_dir%=!"
; (echo(.Set DestinationDir=!destdir!>>"%tmp%\makecab.dir.ddf")
; for %%# in ("%%a\*") do (
; (echo("%%~s#" /inf=no>>"%tmp%\makecab.dir.ddf")
; (echo("%%~f#" /inf=no>>"%tmp%\makecab.dir.ddf")
; )
;)
;(echo(.Set DestinationDir=!dir_name!>>"%tmp%\makecab.dir.ddf")
; for %%# in ("%~f1\*") do (
;
; (echo("%%~s#" /inf=no>>"%tmp%\makecab.dir.ddf")
; (echo("%%~f#" /inf=no>>"%tmp%\makecab.dir.ddf")
; )

;makecab /F "%~f0" /f "%tmp%\makecab.dir.ddf" /d DiskDirectory1=%cd% /d CabinetNameTemplate=%cab_file%.cab
;del /q /f "%tmp%\makecab.dir.ddf"
;rem del /q /f "%tmp%\makecab.dir.ddf"
;exit /b %errorlevel%

;;
Expand Down

0 comments on commit 014e348

Please sign in to comment.