Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix generation of environment variable list #91

Merged
1 commit merged into from
Nov 2, 2021
Merged

Fix generation of environment variable list #91

1 commit merged into from
Nov 2, 2021

Conversation

kb2ma
Copy link
Contributor

@kb2ma kb2ma commented Nov 1, 2021

The command below in src/start.sh appends an "=" to each environment variable name in the generated list:

$ env | grep -v -w '_' | awk -F: '{ st = index($0,"=");print substr($1,0,st) ","}' | tr -d "\n"
SHELL=,SESSION_MANAGER=,QT_ACCESSIBILITY=,COLORTERM=, ...

Changing the argument to awk -F removes the "=", as required by su -w

$ env | grep -v -w '_' | awk -F= '{ st = index($0,"=");print substr($1,0,st) ","}' | tr -d "\n"
SHELL,SESSION_MANAGER,QT_ACCESSIBILITY,COLORTERM, ...

Partial fix for #90

Change-type: patch
Signed-off-by: Ken Bannister <kb2ma@runbox.com>
@ghost
Copy link

ghost commented Nov 1, 2021

Your landr site preview has been successfully deployed to https://landr-balenablocks-repo-browser-preview-91.netlify.app

Deployed with Landr 6.35.1

Copy link
Contributor

@phil-d-wilson phil-d-wilson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've not tested this, but happy to accept as-is. :)

Thanks Ken!

@ghost ghost merged commit a6af959 into master Nov 2, 2021
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants