just a dummy repo for a dummy package

vars.sh 4.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. #!/bin/bash
  2. #shellcheck disable=SC2034
  3. # MKit - simple install helper
  4. # See LICENSE file for copyright and license details.
  5. #
  6. # Add 'async' tag to build meta-data (true|false)
  7. #
  8. # If 'true' and during the version computation git branch is behind
  9. # or ahead its remote counterpart, build meta-data (part after '+'
  10. # sign) will contain word 'async'.
  11. #
  12. # This is to warn testers and developers when build was done after
  13. # automatic rebase done by CI system.
  14. #
  15. # Defaults to 'true'.
  16. #
  17. MKIT_ASYNC=${MKIT_ASYNC:-true}
  18. #
  19. # Bump size (for vbump_? and release_?)
  20. #
  21. MKIT_BUMPSIZE=${MKIT_BUMPSIZE:-1}
  22. #
  23. # Debug mode (true|false)
  24. #
  25. MKIT_DEBUG=${MKIT_DEBUG:-false}
  26. #
  27. # Default deploy mode for files
  28. #
  29. MKIT_DEFAULT_MODE="644"
  30. #
  31. # Dry mode (true|false)
  32. #
  33. # Set to true to not install anything. Implies MKIT_DEBUG.
  34. #
  35. MKIT_DRY=${MKIT_DRY:-false}
  36. #
  37. # Is MKit running in CI (true|false)
  38. #
  39. # If MKit is running in CI, it's recommended to set this to 'true'
  40. # to enable one or more useful warnings.
  41. #
  42. # Defaults to 'false'.
  43. #
  44. MKIT_IN_CI=${MKIT_IN_CI:-false}
  45. #
  46. # Path to mkit.ini
  47. #
  48. MKIT_INI=${MKIT_INI:-mkit.ini}
  49. #
  50. # Limit ini expansion depth
  51. #
  52. # To avoid endless loops, this value is subtracted each
  53. # time ini() expands a reference; when zero is reached,
  54. # no more expansions happen.
  55. #
  56. MKIT_INI_EXPAND=2
  57. #
  58. # Path to MKit local config and temp
  59. #
  60. # Typically hidden in project root, here MKit can
  61. # save its temporary lists.
  62. #
  63. MKIT_LOCAL=${MKIT_LOCAL:-.mkit}
  64. #
  65. # Package name
  66. #
  67. # Used as base for tarball and in some default macros.
  68. #
  69. MKIT_PROJ_PKGNAME=""
  70. #
  71. # Add time-based ordinal tag to SemVer build data?
  72. #
  73. # Can be 'none', 'ctime' or 'btime'.
  74. #
  75. # If 'ctime', devel builds have also timestamp-based tag in format of
  76. # `t%Y%m%d%H%M%S`, that is, a small character 't' followed by timestamp
  77. # without non-digit characters. The timestamps are in UTC, ie. timezones
  78. # need not apply. 'btime' has the same format, except that it's derived
  79. # from build time, while 'ctime' is from last commit's commit date.
  80. #
  81. # This helps with deploying development builds where packaging system
  82. # is not SemVer-compliant and makes it hard to install arbitrary version.
  83. # For example, old yum version (as of RHEL-6) will not let you install
  84. # version that it deems older than is installed, making it hard to
  85. # continually upgrade during active development. While packaging
  86. # systems have their own rules (and SemVer says both versions should be
  87. # considered same) this tag will make it more likely to "win" the build
  88. # you made later.
  89. #
  90. # Note that this does not affect clean builds (ie. builds from clean
  91. # repo with HEAD corresponding to latest version tag.).
  92. #
  93. # Also note that 'btime' makes the version non-deterministic: merely
  94. # initiating the build a second later will result in different version.
  95. #
  96. MKIT_TSTAMP=${MKIT_TSTAMP:-ctime}
  97. #
  98. # Upstream hash to add to build meta-data
  99. #
  100. # If set to non-empty string, it must represent a short-hash of
  101. # upstream commit on which local branch was automatically rebased
  102. # before build.
  103. #
  104. # If CI system automatically rebases branches, the resulting short-hash
  105. # (appearing with `g` prefix) will be meaningless, and might be
  106. # misleading -- testers and developers might see the build as coming
  107. # from an unknown source.
  108. #
  109. # In that case, it's strongly recommended for CI to set this to the
  110. # original pushed short-hash before the rebase. Resulting meta-data
  111. # will contain both hashes, allowing users to pair test results with
  112. # original push. The appearance of the extra hash will also warn
  113. # about the fact that the rebase took place.
  114. #
  115. # For example, if developer pushed branch 'foo' that pointed to
  116. # `5faf551`, and CI system rebased it, altering the HEAD to
  117. # `bb4baa4`, by default the version would look like:
  118. #
  119. # 0.0.1+t202103011224.foo.gbb4baa4
  120. #
  121. # This would be meaningless for testing, as the `bb4baa4` hash is
  122. # completely temporary and unknonwn.
  123. #
  124. # However, a conformant CI should set `MKIT_UPSTREAM=5faf551`, which
  125. # will result in version like:
  126. #
  127. # 0.0.1+t202103011224.foo.gbb4baa4.u5faf551
  128. #
  129. # which still has technically correct git hash after `g`, but contains
  130. # the original hash as pushed after `u`.
  131. #
  132. # Defaults to empty value.
  133. #
  134. MKIT_UPSTREAM=${MKIT_UPSTREAM:-}
  135. #
  136. # This MKit version
  137. #
  138. MKIT_VERSION=0.0.56