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 6075463
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T10:29:51+00:00 2026-05-23T10:29:51+00:00

i m using subversion (Xcode) to commit my files , i would like to

  • 0

i m using subversion (Xcode) to commit my files , i would like to add my svn info on all my file headers – please let me know is any other script available to do this ?

Like

Node Kind: directory
Schedule: normal
Last Changed Author: karthikeyan
Last Changed Rev: 9
Last Changed Date: 2011-06-21 23:55:20 +0530 (Tue, 21 Jun 2011)

#import "TestController.h"
@implementation TestController
  • 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-05-23T10:29:51+00:00Added an answer on May 23, 2026 at 10:29 am

    Shell-fu to the rescue…

    I don’t know what ‘Node Kind’ and ‘Schedule’ are, but do the following:

    Put the following in a shell script, call it insert_header.sh for argument’s sake:

    #!/bin/bash
    
    FILE=$1
    
    sed '1s:^:\
    :
    1i\
    Node Kind: directory
    1i\
    Schedule: normal
    1i\
    Last Changed Author: $Author$
    1i\
    Last Changed Rev: $Rev$
    1i\
    Last Changed Date: $LastChangedDate$
    ' $FILE > $FILE.somerandombackupextension
    
    mv $FILE.somerandombackupextension $FILE
    

    Open a Terminal session.

    Make the file executable with chmod +x insert_header.sh and put it in your PATH, or run it with its relative path (see below).

    Then, run the following command in your source checkout directory (e.g. if you want to change files with extension .cpp):

    find . -name \*.cpp -exec insert_header.sh {} \; -exec svn propset svn:keywords "Author Rev LastChangedDate" {} \;
    

    Run svn status, and expect to see all the changed files with the following ‘MM’ status code:

    MM      path/to/file1.cpp
    MM      path/to/file2.cpp
    

    If you don’t like the changes, revert with svn revert -R ., otherwise svn commit -m "+1 for opyate ;-)"

    PS I tried it with a dummy project, and it ended up looking like this, which is normal:

    Node Kind: directory
    Schedule: normal
    Last Changed Author: $Author: opyate $
    Last Changed Rev: $Rev: 2 $
    Last Changed Date: $LastChangedDate: 2011-06-30 23:20:33 +0100 (Thu, 30 Jun 2011) $
    
    ...the rest of my file
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We are using Subversion. We would like to 1. search across all commit messages
I know that when using Subversion, adding/copying/renaming files must be done via 'svn add'
Using Subversion I try to commit with: svn ci dir/filename And I get this:
I would like to add SVN support to my application that I'm developing in
I'm trying to setup Xcode SCM using Subversion (SVN) on a network disk (mounted).
I'm using Subversion svn under windows in cmd. How can I check which files
I would like to know as how to commit a file/folder to multiple folders
When using Subversion (svn) for source control with multiple projects I've noticed that the
I started using subversion for one of my projects and it would be absolutely
I'm using subversion (TortoiseSVN) and I want to remove the .svn folders from my

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.