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.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

wallpapers.sh 2.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. #!/bin/sh
  2. set -e
  3. if [ -f ./debian/rules ]; then
  4. echo "Running debuild clean and delete the old debian/rules now. "
  5. echo "Please run bootstrap again!"
  6. [ -f ./debian/changelog ] && debuild -d clean
  7. rm -f debian/rules
  8. exit 1
  9. fi
  10. if [ -f VERSION ]; then
  11. . ./VERSION
  12. else
  13. echo "No VERSION-File, exit!"
  14. exit 1
  15. fi
  16. if [ -f FLAVOUR ]; then
  17. . ./FLAVOUR
  18. else
  19. echo "No FLAVOUR-File, exit!"
  20. exit 1
  21. fi
  22. # clean up obsolete stuff
  23. rm -f ./debian/install \
  24. ./debian/ĺinks \
  25. ./debian/postinst \
  26. ./debian/postrm \
  27. ./debian/prerm \
  28. ./debian/preinst
  29. [ -d ./debian ] || exit 1
  30. if [ ! -e ./debian/changelog ]; then
  31. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  32. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  33. -e "s/\@VERSION\@/${VERSION}/g" \
  34. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  35. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  36. templates/debian/changelog \
  37. > ./debian/changelog
  38. fi
  39. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  40. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  41. -e "s/\@VERSION\@/${VERSION}/g" \
  42. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  43. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  44. templates/debian/${FLAVOUR}-control \
  45. > ./debian/control
  46. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  47. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  48. -e "s/\@VERSION\@/${VERSION}/g" \
  49. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  50. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  51. templates/debian/rules \
  52. > ./debian/rules
  53. chmod 755 ./debian/rules
  54. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  55. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  56. -e "s/\@VERSION\@/${VERSION}/g" \
  57. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  58. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  59. templates/debian/source/options \
  60. > ./debian/source/options
  61. rm -f svg/*.svg
  62. for i in templates/wallpapers/svg/*.svg; do
  63. BASENAME=$(basename $i)
  64. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  65. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  66. -e "s/\@VERSION\@/${VERSION}/g" \
  67. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  68. -e "s/\@DISPLAY\@/${DISPLAY}/g" $i \
  69. > ./svg/${BASENAME}
  70. done
  71. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  72. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  73. -e "s/\@VERSION\@/${VERSION}/g" \
  74. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  75. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  76. templates/debian/wallpapers.install \
  77. > ./debian/install
  78. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  79. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  80. -e "s/\@VERSION\@/${VERSION}/g" \
  81. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  82. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  83. templates/debian/wallpapers.links \
  84. > ./debian/links
  85. cp templates/wallpapers/Makefile .
  86. sed -e "s/\@CODENAME_SAFE\@/${NAME}/g" \
  87. -e "s/\@CODENAME\@/${DESCRIPTION}/g" \
  88. -e "s/\@VERSION\@/${VERSION}/g" \
  89. -e "s/\@FLAVOUR\@/${FLAVOUR}/g" \
  90. -e "s/\@DISPLAY\@/${DISPLAY}/g" \
  91. templates/wallpapers/metadata.desktop \
  92. > ./metadata.desktop