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

Minor: Creates overriding makepkg.conf in user directory #30

Closed
CJ1169 opened this issue Nov 2, 2019 · 7 comments
Closed

Minor: Creates overriding makepkg.conf in user directory #30

CJ1169 opened this issue Nov 2, 2019 · 7 comments

Comments

@CJ1169
Copy link

CJ1169 commented Nov 2, 2019

See this link for more information: https://forum.manjaro.org/t/makepkg-ignoring-pkgext-in-makepkg-conf/109338/8
TL;DR Does bauh have to create its own makepkg.conf in the user directory?

@CJ1169 CJ1169 changed the title Minor: Creates overwriting makepkg.conf in user directory Minor: Creates overriding makepkg.conf in user directory Nov 2, 2019
@vinifmor
Copy link
Owner

vinifmor commented Nov 2, 2019

If you have enabled AUR , it will create an optimized version of makepkg in your home folder. This behavior can be disabled via the environment variable BAUH_ARCH_OPTIMIZE=0. This is described in the project README file in the AUR (arch) gem section.

@CJ1169
Copy link
Author

CJ1169 commented Nov 4, 2019

If you have enabled AUR , it will create an optimized version of makepkg in your home folder. This behavior can be disabled via the environment variable BAUH_ARCH_OPTIMIZE=0. This is described in the project README file in the AUR (arch) gem section.

Good to hear the behavior can be modified. However, is it best to have that as the default behavior? I believe it's possible to call makepkg using a custom makepkg.conf that won't be picked up regularly. yay, the aur helper does this, I believe (although not by default).
i.e. maybe in a ~/.config/bauh directory, a makepkg.conf file could be used and then makepkg directed to use that instead.

Also good work my dude!

@vinifmor
Copy link
Owner

vinifmor commented Nov 6, 2019

I added this behavior with new Linux users in mind. Non-tech people that don't know anything about compilation and probably won't like some AUR applications taking too long to install. bauh just make a copy of your /etc/makepkg.conf in your home folder and add these two lines ( if you haven't defined a value for them ):

MAKEFLAGS="-j$(nproc)"
COMPRESSXZ=(xz -c -z - --threads=0)

In the next future, I will add a settings window where you can see all bauh options and enable / disable them.

About informing a custom makepkg, I agree with you that is a better way and was the first thing that came in mind when I was coding. Unfortunately, I didn't find any other way at the time. If you know how to do it, please let me know, and I will change it for the next release.

Cheers

@CJ1169
Copy link
Author

CJ1169 commented Nov 6, 2019

I added this behavior with new Linux users in mind. Non-tech people that don't know anything about compilation and probably won't like some AUR applications taking too long to install. bauh just make a copy of your /etc/makepkg.conf in your home folder and add these two lines ( if you haven't defined a value for them ):

MAKEFLAGS="-j$(nproc)" COMPRESSXZ=(xz -c -z - --threads=0)

In the next future, I will add a settings window where you can see all bauh options and enable / disable them.

About informing a custom makepkg, I agree with you that is a better way and was the first thing that came in mind when I was coding. Unfortunately, I didn't find any other way at the time. If you know how to do it, please let me know, and I will change it for the next release.

Cheers

Makes sense!
As for passing a custom config to makepkg, I believe
exec:

	if config.MakepkgConf != "" {
		args = append(args, "--config", config.MakepkgConf)
	}

config:

		MakepkgConf:        "",

Does it in Go. This was taken from yay's source code.
TL;DR: passing --config "/etc/makepkg.conf" should do it?
Goodluck! :)

@CJ1169 CJ1169 closed this as completed Nov 6, 2019
@vinifmor
Copy link
Owner

@CJ1169, sorry for the late response and thank you for your help. I will change the behavior this week and release 0.7.3 with it.

@vinifmor
Copy link
Owner

vinifmor commented Nov 27, 2019

Already done. If you want to have a look at the code changes -> 374c697

In the end of the day I will be publishing it to AUR in bauh-staging package.

@CJ1169
Copy link
Author

CJ1169 commented Nov 27, 2019

Good to hear! Lovely work

@vinifmor vinifmor mentioned this issue Nov 29, 2019
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

No branches or pull requests

2 participants