I'm building OpenWRT from source for my
Linkit Smart 7688 board. It turns out quite well, but my command prompt seems not being translated properly.
The command prompt is kept as
\u@\h:\w\ instead of replacing the them with their respective string. And login prompt failed to get the hostname too. (It's
(none) in my case, as shown in the pic above.)
This is my build option for
I've also enabled
fgrep applet as it seems that
/etc/profile requires it to work properly.
I'm not sure what I'm missing here, any advice is greatly appreciated
Can you paste here the PS1 line?
That's weird.... looks like
$PS1 is empty
It's easier to paste the text rather than the screenshots.
The second export is not working properly. You are missing some opening square bracket and you are appending the whole user@host in the second line.
root@magiatiko:[/]#export PS1='\u@\h:\w\$ '
root@magiatiko:/# export PS1='\[\e\]0;\u@\h: \w\a\]'$PS1
Sorry for the screenshot
But hmmm actually I didn't make any change to
/etc/profile, it came straight from github : https://github.com/openwrt/openwrt/blob/master/package/base-files/files/etc/profile
I'll try the bashrcgenerator you suggested, thanks a lot!
Yeah, I mistyped and it created a mistake. The actual lines in profile are correct. Did you add the PS1 anywhere else, like
No, I didn't do anything shell related apart from those in menuconfig.
I think I should try rebuild again with default configuration and see what changes I made affected the shell.
Big Thank You for all your replies, I think I found the problem!
The shell prompt did not work correctly because I disabled
Fancy shell prompts under
Base System > busybox > Settings
It's so easy to miss because it's not under shell configuration submenu, but now I've enabled it and problem solved
This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.