How do I remove an alias?












153















I want to remove gs alias from my PC. When I type gs it will open GhostScript. But I checked everywhere in the home directory .alias .bash_aliases .bashrc



I also overwrite the gs with my custom alias.



I can't remove it. And I also type alias in terminal, in the list I couldn't find it.



Please I want to remove it...










share|improve this question




















  • 3





    gs isn't an alias, it's the name of the GhostScript binary. If you want gs to do nothing then you would have to uninstall ghostscript from your system although this probably isn't a good idea as a lot of other software depends on it.

    – Cheesemill
    Jul 27 '13 at 18:52













  • @Cheesemill and that explains the ? I had in my head. Why do you assume it is aliased jean000? :)

    – Rinzwind
    Jul 27 '13 at 18:58






  • 2





    You can use type gs to check if the command is an executable file, an alias, a bash function or a bash builtin.

    – Håken Lid
    Oct 9 '15 at 19:33











  • alias --help, unhelpfully, does not reveal any useful answer to this question

    – Purplejacket
    Apr 14 '17 at 20:50
















153















I want to remove gs alias from my PC. When I type gs it will open GhostScript. But I checked everywhere in the home directory .alias .bash_aliases .bashrc



I also overwrite the gs with my custom alias.



I can't remove it. And I also type alias in terminal, in the list I couldn't find it.



Please I want to remove it...










share|improve this question




















  • 3





    gs isn't an alias, it's the name of the GhostScript binary. If you want gs to do nothing then you would have to uninstall ghostscript from your system although this probably isn't a good idea as a lot of other software depends on it.

    – Cheesemill
    Jul 27 '13 at 18:52













  • @Cheesemill and that explains the ? I had in my head. Why do you assume it is aliased jean000? :)

    – Rinzwind
    Jul 27 '13 at 18:58






  • 2





    You can use type gs to check if the command is an executable file, an alias, a bash function or a bash builtin.

    – Håken Lid
    Oct 9 '15 at 19:33











  • alias --help, unhelpfully, does not reveal any useful answer to this question

    – Purplejacket
    Apr 14 '17 at 20:50














153












153








153


20






I want to remove gs alias from my PC. When I type gs it will open GhostScript. But I checked everywhere in the home directory .alias .bash_aliases .bashrc



I also overwrite the gs with my custom alias.



I can't remove it. And I also type alias in terminal, in the list I couldn't find it.



Please I want to remove it...










share|improve this question
















I want to remove gs alias from my PC. When I type gs it will open GhostScript. But I checked everywhere in the home directory .alias .bash_aliases .bashrc



I also overwrite the gs with my custom alias.



I can't remove it. And I also type alias in terminal, in the list I couldn't find it.



Please I want to remove it...







command-line alias






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 10 hours ago









Kevin Bowen

14.5k155970




14.5k155970










asked Jul 27 '13 at 17:51









jean000jean000

866263




866263








  • 3





    gs isn't an alias, it's the name of the GhostScript binary. If you want gs to do nothing then you would have to uninstall ghostscript from your system although this probably isn't a good idea as a lot of other software depends on it.

    – Cheesemill
    Jul 27 '13 at 18:52













  • @Cheesemill and that explains the ? I had in my head. Why do you assume it is aliased jean000? :)

    – Rinzwind
    Jul 27 '13 at 18:58






  • 2





    You can use type gs to check if the command is an executable file, an alias, a bash function or a bash builtin.

    – Håken Lid
    Oct 9 '15 at 19:33











  • alias --help, unhelpfully, does not reveal any useful answer to this question

    – Purplejacket
    Apr 14 '17 at 20:50














  • 3





    gs isn't an alias, it's the name of the GhostScript binary. If you want gs to do nothing then you would have to uninstall ghostscript from your system although this probably isn't a good idea as a lot of other software depends on it.

    – Cheesemill
    Jul 27 '13 at 18:52













  • @Cheesemill and that explains the ? I had in my head. Why do you assume it is aliased jean000? :)

    – Rinzwind
    Jul 27 '13 at 18:58






  • 2





    You can use type gs to check if the command is an executable file, an alias, a bash function or a bash builtin.

    – Håken Lid
    Oct 9 '15 at 19:33











  • alias --help, unhelpfully, does not reveal any useful answer to this question

    – Purplejacket
    Apr 14 '17 at 20:50








3




3





gs isn't an alias, it's the name of the GhostScript binary. If you want gs to do nothing then you would have to uninstall ghostscript from your system although this probably isn't a good idea as a lot of other software depends on it.

– Cheesemill
Jul 27 '13 at 18:52







gs isn't an alias, it's the name of the GhostScript binary. If you want gs to do nothing then you would have to uninstall ghostscript from your system although this probably isn't a good idea as a lot of other software depends on it.

– Cheesemill
Jul 27 '13 at 18:52















@Cheesemill and that explains the ? I had in my head. Why do you assume it is aliased jean000? :)

– Rinzwind
Jul 27 '13 at 18:58





@Cheesemill and that explains the ? I had in my head. Why do you assume it is aliased jean000? :)

– Rinzwind
Jul 27 '13 at 18:58




2




2





You can use type gs to check if the command is an executable file, an alias, a bash function or a bash builtin.

– Håken Lid
Oct 9 '15 at 19:33





You can use type gs to check if the command is an executable file, an alias, a bash function or a bash builtin.

– Håken Lid
Oct 9 '15 at 19:33













alias --help, unhelpfully, does not reveal any useful answer to this question

– Purplejacket
Apr 14 '17 at 20:50





alias --help, unhelpfully, does not reveal any useful answer to this question

– Purplejacket
Apr 14 '17 at 20:50










1 Answer
1






active

oldest

votes


















190














The command to remove an alias is unalias so....



 unalias gs


Manual:



NAME




unalias - remove alias definitions




SYNOPSIS



unalias alias-name...

unalias -a


DESCRIPTION




The unalias utility shall remove the definition for each alias name
specified. See Alias Substitution . The aliases shall be removed from
the current shell execution environment; see Shell Execution
Environment .



-a Removes All aliases







share|improve this answer


























  • not working I got unalias: no such hash table element: gs

    – jean000
    Jul 27 '13 at 18:41






  • 10





    Then you do NOT have it alias'd.

    – Rinzwind
    Jul 27 '13 at 18:45






  • 7





    caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

    – Huey
    Nov 21 '14 at 12:48






  • 1





    @assylias I missed that :) edited

    – Rinzwind
    May 20 '15 at 11:42






  • 1





    unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

    – sudodus
    Mar 19 '18 at 17:02











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f325368%2fhow-do-i-remove-an-alias%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









190














The command to remove an alias is unalias so....



 unalias gs


Manual:



NAME




unalias - remove alias definitions




SYNOPSIS



unalias alias-name...

unalias -a


DESCRIPTION




The unalias utility shall remove the definition for each alias name
specified. See Alias Substitution . The aliases shall be removed from
the current shell execution environment; see Shell Execution
Environment .



-a Removes All aliases







share|improve this answer


























  • not working I got unalias: no such hash table element: gs

    – jean000
    Jul 27 '13 at 18:41






  • 10





    Then you do NOT have it alias'd.

    – Rinzwind
    Jul 27 '13 at 18:45






  • 7





    caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

    – Huey
    Nov 21 '14 at 12:48






  • 1





    @assylias I missed that :) edited

    – Rinzwind
    May 20 '15 at 11:42






  • 1





    unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

    – sudodus
    Mar 19 '18 at 17:02
















190














The command to remove an alias is unalias so....



 unalias gs


Manual:



NAME




unalias - remove alias definitions




SYNOPSIS



unalias alias-name...

unalias -a


DESCRIPTION




The unalias utility shall remove the definition for each alias name
specified. See Alias Substitution . The aliases shall be removed from
the current shell execution environment; see Shell Execution
Environment .



-a Removes All aliases







share|improve this answer


























  • not working I got unalias: no such hash table element: gs

    – jean000
    Jul 27 '13 at 18:41






  • 10





    Then you do NOT have it alias'd.

    – Rinzwind
    Jul 27 '13 at 18:45






  • 7





    caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

    – Huey
    Nov 21 '14 at 12:48






  • 1





    @assylias I missed that :) edited

    – Rinzwind
    May 20 '15 at 11:42






  • 1





    unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

    – sudodus
    Mar 19 '18 at 17:02














190












190








190







The command to remove an alias is unalias so....



 unalias gs


Manual:



NAME




unalias - remove alias definitions




SYNOPSIS



unalias alias-name...

unalias -a


DESCRIPTION




The unalias utility shall remove the definition for each alias name
specified. See Alias Substitution . The aliases shall be removed from
the current shell execution environment; see Shell Execution
Environment .



-a Removes All aliases







share|improve this answer















The command to remove an alias is unalias so....



 unalias gs


Manual:



NAME




unalias - remove alias definitions




SYNOPSIS



unalias alias-name...

unalias -a


DESCRIPTION




The unalias utility shall remove the definition for each alias name
specified. See Alias Substitution . The aliases shall be removed from
the current shell execution environment; see Shell Execution
Environment .



-a Removes All aliases








share|improve this answer














share|improve this answer



share|improve this answer








edited Mar 19 '18 at 16:51









mkobit

1075




1075










answered Jul 27 '13 at 18:06









RinzwindRinzwind

206k28395527




206k28395527













  • not working I got unalias: no such hash table element: gs

    – jean000
    Jul 27 '13 at 18:41






  • 10





    Then you do NOT have it alias'd.

    – Rinzwind
    Jul 27 '13 at 18:45






  • 7





    caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

    – Huey
    Nov 21 '14 at 12:48






  • 1





    @assylias I missed that :) edited

    – Rinzwind
    May 20 '15 at 11:42






  • 1





    unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

    – sudodus
    Mar 19 '18 at 17:02



















  • not working I got unalias: no such hash table element: gs

    – jean000
    Jul 27 '13 at 18:41






  • 10





    Then you do NOT have it alias'd.

    – Rinzwind
    Jul 27 '13 at 18:45






  • 7





    caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

    – Huey
    Nov 21 '14 at 12:48






  • 1





    @assylias I missed that :) edited

    – Rinzwind
    May 20 '15 at 11:42






  • 1





    unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

    – sudodus
    Mar 19 '18 at 17:02

















not working I got unalias: no such hash table element: gs

– jean000
Jul 27 '13 at 18:41





not working I got unalias: no such hash table element: gs

– jean000
Jul 27 '13 at 18:41




10




10





Then you do NOT have it alias'd.

– Rinzwind
Jul 27 '13 at 18:45





Then you do NOT have it alias'd.

– Rinzwind
Jul 27 '13 at 18:45




7




7





caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

– Huey
Nov 21 '14 at 12:48





caution: unalias -a will remove all alias definitions from the current shell execution environment., possibly including other innocent ones.

– Huey
Nov 21 '14 at 12:48




1




1





@assylias I missed that :) edited

– Rinzwind
May 20 '15 at 11:42





@assylias I missed that :) edited

– Rinzwind
May 20 '15 at 11:42




1




1





unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

– sudodus
Mar 19 '18 at 17:02





unalias removes an alias or aliases from the current shell, but if they are 'stored' in for example ~/.bashrc, they will come back when you create a new shell (or terminal window). So you should remove the definition of the aliases from where they are stored in order to get rid of them, unless they are temporary aliases.

– sudodus
Mar 19 '18 at 17:02


















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f325368%2fhow-do-i-remove-an-alias%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

How did Captain America manage to do this?

迪纳利

南乌拉尔铁路局