git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Markus Heller <hellerm2@gmail.com>
To: git@vger.kernel.org
Subject: Run git from .bat file (Windows)
Date: Tue, 20 Jul 2010 09:34:43 -0700	[thread overview]
Message-ID: <0vy6d6nmcc.fsf@gmail.com> (raw)

Hello,

I'm trying to get the script below working on a box with Windoze XP and
git version 1.7.0.2.msysgit.0.  The script is a .bat file and is
supposed to be run from the Windoze scheduler; for testing, I run it
from a command prompt.

Here's the script:

=================8<==================8<=====================
@ECHO OFF

REM get date and time
for /f "delims=" %%a in ('date/t') do @set mydate=%%a
for /f "delims=" %%a in ('time/t') do @set mytime=%%a
set fvar=%mydate%%mytime%

REM add all new files
git add .
git commit -a -m "Automated commit by org-git-sync.bat on %fvar%"
================>8===================>8======================

The line "git add ." works, as I can see the additions when I type "git
status" after executing the script.  Committing doesn't work, however:
"git log" shows that no commit was created.

Any idea what's going on?

Thanks
Markus

             reply	other threads:[~2010-07-20 16:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-20 16:34 Markus Heller [this message]
2010-07-20 17:34 ` Run git from .bat file (Windows) Peter Harris
2010-07-20 18:44   ` Markus Heller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0vy6d6nmcc.fsf@gmail.com \
    --to=hellerm2@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).