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

  • SEARCH
  • Home
  • 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 7790671
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T21:39:21+00:00 2026-06-01T21:39:21+00:00

After logging into my account in linux – I am able to use all

  • 0

After logging into my account in linux – I am able to use all the alias I have created in my .bash_profile file.

But after I am executing a simple script (setter.sh) with the command:
cleartool setview view_name

All the alias are getting lost – this could be possibly because cleartool spawns a new shell
Query is:

  1. How to determine how many shells are spawned currently – can I know at which nesting level am I currently in – if a script works in such a way that is spawns new shell?.

  2. How to retain the alias values after launching new shell – Like in the above case?

  3. If I try to ensure that .bash_profile get’s re-executed as part of the script by adding source .bash_profile – even then – the alias setting is not taking place?.

  • 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-01T21:39:23+00:00Added an answer on June 1, 2026 at 9:39 pm

    You should have googled on .bash_profile and you would have found that .bash_profile is for login shells, .bashrc is for interactive shells, and that shell scripts don’t use them.

    Within shell scripts, better use functions (which you’ll have to define) than aliases.

    The shell level of subshells is available thru the SHLVL variable.

    Take time to read the Advanced Bash-Scripting Guide.

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

Sidebar

Related Questions

Currently I'm logging into my account. After proceeding some of the pages I have
I've found a code which opens this link after logging in to google account
Every morning, after logging into your machine, you do a variety of routine stuffs.
We have a SSO solution with ADFS for logging into our web app, we
After logging into SO, my nickname shows up at the top. When I set
I'm getting a pretty nasty KeyError after logging into the Django admin. It is
This is the error I get after logging into Stack with my LightOpenID provider
HI, I am able to login into the site using php and curl. but
logging into django admin fails when 'log in' button is pressed first time, but
I'm trying to use console.log to put some logging into the javascript side 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.