summaryrefslogblamecommitdiff
path: root/tools/get-scala-commit-sha.bat
blob: 7a5afa11b1dae42aea80571d562d9179110b2147 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
















                                                       
                       


         
@echo off
rem
rem Usage: get-scala-commit-drift.bat [dir]
rem Figures out current scala commit drift, of a clone.
rem
rem If no dir is given, current working dir is used.

@setlocal
set _DIR=
if "%*"=="" (
  for /f "delims=;" %%i in ('cd') do set "_DIR=%%i"
) else (
  set "_DIR=%~1"
)
cd %_DIR%

rem  TODO - truncate chars.
git log -1 --format="%H

:end
@endlocal