Skip to content

Magenaut

  • Home
  • Topics
    • Notes
    • Tutorial
    • Bug fixing
    • Extension
    • Server
  • Q&A
  • Privacy Policy
  • About

function

Circular name references in bash shell function, but not in ksh

August 9, 2022 by Magenaut

I’m writing a set of shell functions that I want to have working in both Bash and KornShell93, but with Bash I’m running into a “circular name reference” warning.

Categories Q&A, Unix & Linux Tags bash, function, ksh, typeset, variable Leave a comment

What return/exit values can I use in bash functions/scripts?

August 9, 2022 by Magenaut

I want to know what return values we can use that will not be mistaken by for ex. SIGINT?

Categories Q&A, Unix & Linux Tags bash, exit, exit-status, function, shell Leave a comment

call function declared below

August 9, 2022 by Magenaut

Is it possible to call a function which is declared below in bash?

Categories Q&A, Unix & Linux Tags function, linux, shell-script Leave a comment

How to add a function to .bash_profile/.profile/bashrc in shell?

August 9, 2022 by Magenaut

I have a function which converts epoch time to date. Here is the definition

Categories Q&A, Unix & Linux Tags bash, function, profile, shell Leave a comment

what is the zsh equivalent of bash’s export -f

August 9, 2022 by Magenaut

So I started using zsh. I like it all right. It seems very cool and slick, and the fact that the current working directory and actual command line are on different lines is nice, but at the same time, I’m noticing that zsh can be a bit slower than bash, especially when printing text to the screen.

Categories Q&A, Unix & Linux Tags function, shell-script, zsh Leave a comment

What is “declare” in Bash?

August 9, 2022 by Magenaut

After reading ilkkachu’s answer to this question I learned on the existence of the declare (with argument -n) shell built in.

Categories Q&A, Unix & Linux Tags bash, control-flow, declare, function, shell-builtin Leave a comment

Shell valid function name characters

August 8, 2022 by Magenaut

Using extended Unicode characters is (no-doubt) useful for many users.

Categories Q&A, Unix & Linux Tags bash, function, shell, zsh Leave a comment

How to determine callee function name in a script

August 8, 2022 by Magenaut

To make it short, doing something like:

Categories Q&A, Unix & Linux Tags bash, function, shell-script Leave a comment

What are commands to find shell keywords, built in functions and user defined functions?

August 8, 2022 by Magenaut

I was discussing with my friend on how the commands are parsed in the shell, and he told me that bash searches the command in following order

Categories Q&A, Unix & Linux Tags alias, command, function, shell Leave a comment

View shell function’s current definition

August 8, 2022 by Magenaut

So I am editing bashrc constantly, and I have a terminal open with a working function definition, although bashrc has been updated with a wrong function definition. (Because the definition do not change until I source the updated bashrc) How can I look up the working function definition in this case? For example, if I type:

Categories Q&A, Unix & Linux Tags bashrc, function Leave a comment
Older posts
Newer posts
← Previous Page1 … Page9 Page10 Page11 Next →
  1. michealSmith07 on Is there a way to dynamically refresh the less command?August 21, 2022

    That is a very nice post. I like this post.

  2. anonymous on Fix libwacom9 dependency issue when upgrade DebianJune 27, 2022

    saved my day!! Thanks for the help…

  3. sreedhar on Fix libwacom9 dependency issue when upgrade DebianMay 10, 2022

    Thanks its working

  4. saintnick on Fix libwacom9 dependency issue when upgrade DebianMay 10, 2022

    remove libwacom2 worked for me as well

  5. ranafoul on Fix libwacom9 dependency issue when upgrade DebianApril 22, 2022

    apt remove libwacom2 helped on kali 2022.01. gr8

.net ajax asp.net asp.net-core asp.net-mvc asp.net-mvc-3 asp.net-mvc-4 asp.net-web-api bash c# command-line css custom-post-types custom-taxonomy dataframe dictionary django entity-framework functions gridview html iis javascript jquery json linux list matplotlib numpy pandas php plugin-development plugins posts python python-2.7 python-3.x security shell shell-script sql string vb.net webforms wp-query

© 2026 Magenaut • Built with GeneratePress