Merge branch 'develop' of github.com:RiV-chain/RiV-mesh into develop

This commit is contained in:
vadym 2021-09-13 15:00:54 +03:00
commit e7de29eb62
2 changed files with 16 additions and 40 deletions

View file

@ -17,30 +17,6 @@ if [ $? != 0 ] || [ -z "$BRANCH" ]; then
BRANCH="master" BRANCH="master"
fi fi
# Split out into major, minor and patch numbers STAG=$(echo $TAG | sed 's/v//' | sed 's/[^0123456789.].//')
MAJOR=$(echo $TAG | cut -c 2- | cut -d "." -f 1)
MINOR=$(echo $TAG | cut -c 2- | cut -d "." -f 2)
PATCH=$(echo $TAG | cut -c 2- | cut -d "." -f 3 | awk -F"rc" '{print $1}')
# Output in the desired format printf '%s' "$STAG"
if [ $((PATCH)) -eq 0 ]; then
printf '%s%d.%d' "$PREPEND" "$((MAJOR))" "$((MINOR))"
else
printf '%s%d.%d.%d' "$PREPEND" "$((MAJOR))" "$((MINOR))" "$((PATCH))"
fi
# Add the build tag on non-master branches
if [ "$BRANCH" != "master" ]; then
BUILD=$(git rev-list --count $TAG..HEAD 2>/dev/null)
# Did getting the count of commits since the tag succeed?
if [ $? != 0 ] || [ -z "$BUILD" ]; then
printf -- "-unknown"
exit 0
fi
# Is the build greater than zero?
if [ $((BUILD)) -gt 0 ]; then
printf -- "-%04d" "$((BUILD))"
fi
fi

View file

@ -5,21 +5,21 @@ package defaults
// Sane defaults for the Windows platform. The "default" options may be // Sane defaults for the Windows platform. The "default" options may be
// may be replaced by the running configuration. // may be replaced by the running configuration.
func GetDefaults() platformDefaultParameters { func GetDefaults() platformDefaultParameters {
return platformDefaultParameters{ return platformDefaultParameters{
// Admin // Admin
DefaultAdminListen: "tcp://localhost:9001", DefaultAdminListen: "tcp://localhost:9001",
// Configuration (used for meshctl) // Configuration (used for meshctl)
DefaultConfigFile: "C:\\Program Files\\RiV-mesh\\mesh.conf", DefaultConfigFile: "C:\\Program Files\\RiV-mesh\\mesh.conf",
// Multicast interfaces // Multicast interfaces
DefaultMulticastInterfaces: []MulticastInterfaceConfig{ DefaultMulticastInterfaces: []MulticastInterfaceConfig{
{Regex: ".*", Beacon: true, Listen: true}, {Regex: ".*", Beacon: true, Listen: true},
}, },
// TUN/TAP // TUN/TAP
MaximumIfMTU: 65535, MaximumIfMTU: 65535,
DefaultIfMTU: 65535, DefaultIfMTU: 65535,
DefaultIfName: "RiV-mesh", DefaultIfName: "RiV-mesh",
} }
} }