Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8975949
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T19:00:29+00:00 2026-06-15T19:00:29+00:00

I have a code base that some of the developers work on via RDP

  • 0

I have a code base that some of the developers work on via RDP and use the IDE that is on the remote machine. I would like to know if there is a way to force them to enter their own name when committing changes. Right now Git is defaulting to my name which is incredibly annoying since I am not the one making the changes.

Also when something is pushed to GitHub, it does ask for user name/password, but I can’t seem to find any indication of that user’s information in the commit list.

** EDIT ** FYI **

My original intention was to force a user signed in under a shared account (unavoidable) to enter their user.name and user.email credentials each time the commit command was run. In order to accomplish this, I tried to use a login script for Windows that would essentially clear and set these values each time a new person logged in;

@echo off
cls

REM * Notify user
echo Clearing Git user information...

REM * Go to Git directory
cd C:\"Program Files (x86)"\Git\bin\

REM * Clear user information
git config --global --remove-section user

REM * Get the user's name
set /p name= Please enter your first name:

REM * Get user email
set /p email= Please enter your email:

REM * Set Git configuration
git config --global user.name "%name%"
git config --global user.email "%email%"
::REM * exit
exit

But I could not get it to work consistently via RDP which is its main use case.

This lead me to try to use the pre-commit hook for Git which I used essentially the same script modified for Bash. This also didn’t work, because Git assigns the “author” before calling the hook.

In other words, if the user configuration was name = jim and email = bob@test.com the Git log would have the author as jim<bob@test.com> and then the next commit would have the entered information.

#!/bin/sh
#
exec < /dev/tty

# Notify user
echo "Clearing Git user information..."

# Go to Git directory
#cd c:\"Program Files (x86)"\Git\bin\

# Clear user information
git config --global --remove-section user

# Get the user's name
echo "Please enter your first name: "
read name

# Get user email
echo "Please enter your email: "
read email

echo name: $name email: $email
read -n 1

# Set Git configuration
git config --global user.email $email
git config --global user.name $name
#exit
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T19:00:30+00:00Added an answer on June 15, 2026 at 7:00 pm

    You look to be in a dirty development setup, so something as dirty:

    Make a logon script that erases Git’s user name and email, the developers will have to enter it at each time they connect to the machine.

    git config --remove-section user
    

    Git will then ask for name/email on the first run if it’s not configured.

    Of course, creating Windows user sessions and having per-user Git configuration is better 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a code base that has been used as an ASP.Net web application.
I have a code-base that I'm looking to split up and add to by
I have a code base that deals with simulation of certain data. It involves
is there any development environments that allow you to have one code base that
I have an existing code base that is not packaged at all. The code
In my code base I find that two modules have structures with the same
I have this program that should execute a piece of code base on the
I have a bit old project that I would call legacy. Some characteristics of
I have some code that has a dynamic-class system in C++ that has a
I work on a code base in the region of about 1'000'000 lines of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.