2

I'm a newbie, and maybe I don't have the good keywords for my search. Here's my question.

I'm trying to generate a md (markdown) file and I want to know if it is possible to get the current username, as i'm inside a gitlab project.

To get an output like

I'm "username" 

when reading the markdown file.

Thanks for your explanation !

metastack
  • 41
  • 3
  • how are you generating the Markdown file? If you're using bash, it's simply: `echo "I'm \"$(whoami)\"" > something.md` – ddavison Feb 23 '16 at 14:55
  • I'm inside firefox, accessing gitlab, so I unfortunately can't do it ! – metastack Feb 23 '16 at 15:08
  • related: http://stackoverflow.com/a/32254521/866026 – Waylan Feb 23 '16 at 16:46
  • Perhaps this is not what you want, but a shortcut for GitLab namespaces is using `@mentions`. So, your username is `@username`. But, as I said, I'm not sure this is good enough for your needs... – Virtua Creative Feb 28 '16 at 14:37

1 Answers1

2

I'm assuming you are just talking about a markdown file in a GitLab repository. In that case, it's not possible since it's only a static file and the GitLab server doesn't do any processing on it. So there's no way to have it display differently for each user.

mb21
  • 34,845
  • 8
  • 116
  • 142