You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.2 KiB

  1. #
  2. # Copyright (C) 2019 Jeffery To
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=shinit
  9. PKG_VERSION:=0.1.0
  10. PKG_RELEASE:=1
  11. PKG_LICENSE:=GPL-2.0-only
  12. PKG_MAINTAINER:=Jeffery To <jeffery.to@gmail.com>
  13. include $(INCLUDE_DIR)/package.mk
  14. define Package/shinit
  15. SECTION:=utils
  16. CATEGORY:=Utilities
  17. TITLE:=Initialization for all interactive shells (login or not)
  18. PKGARCH:=all
  19. endef
  20. define Package/shinit/description
  21. This package adds support for /etc/shinit and ~/.shinit files, which
  22. contain commands to be run at the start of all interactive shells.
  23. (/etc/profile and ~/.profile are read for login shells only.)
  24. This is useful for those who regularly open non-login, interactive
  25. shells, for example users of GNU Screen or tmux.
  26. endef
  27. define Package/shinit/conffiles
  28. /etc/shinit
  29. endef
  30. Build/Prepare:=:
  31. Build/Configure:=:
  32. Build/Compile:=:
  33. define Package/shinit/install
  34. $(INSTALL_DIR) $(1)/etc
  35. $(INSTALL_DATA) ./files/etc/shinit $(1)/etc
  36. $(INSTALL_DIR) $(1)/etc/profile.d
  37. $(INSTALL_DATA) ./files/etc/profile.d/shinit.sh $(1)/etc/profile.d
  38. endef
  39. $(eval $(call BuildPackage,shinit))