diff --git a/Makefile b/Makefile index 9a5aaab76..a04366033 100644 --- a/Makefile +++ b/Makefile @@ -6,20 +6,20 @@ PROJECT_VERSION = 3.0 DEPS = jsx gproc gen_rpc ekka esockd cowboy clique -dep_jsx = git https://github.com/talentdeficit/jsx 2.9.0 -dep_gproc = git https://github.com/uwiger/gproc 0.8.0 -dep_gen_rpc = git https://github.com/emqx/gen_rpc 2.3.0 -dep_esockd = git https://github.com/emqx/esockd v5.4.2 -dep_ekka = git https://github.com/emqx/ekka v0.5.1 -dep_cowboy = git https://github.com/ninenines/cowboy 2.4.0 -dep_clique = git https://github.com/emqx/clique develop +dep_jsx = hex-emqx 2.9.0 +dep_gproc = hex-emqx 0.8.0 +dep_gen_rpc = git-emqx https://github.com/emqx/gen_rpc 2.3.0 +dep_esockd = git-emqx https://github.com/emqx/esockd v5.4.2 +dep_ekka = git-emqx https://github.com/emqx/ekka v0.5.1 +dep_cowboy = hex-emqx 2.4.0 +dep_clique = git-emqx https://github.com/emqx/clique develop NO_AUTOPATCH = cuttlefish ERLC_OPTS += +debug_info -DAPPLICATION=emqx BUILD_DEPS = cuttlefish -dep_cuttlefish = git https://github.com/emqx/cuttlefish v2.1.1 +dep_cuttlefish = git-emqx https://github.com/emqx/cuttlefish v2.1.1 #TEST_DEPS = emqx_ct_helplers #dep_emqx_ct_helplers = git git@github.com:emqx/emqx-ct-helpers @@ -47,6 +47,20 @@ PLT_APPS = sasl asn1 ssl syntax_tools runtime_tools crypto xmerl os_mon inets pu DIALYZER_DIRS := ebin/ DIALYZER_OPTS := --verbose --statistics -Werror_handling -Wrace_conditions #-Wunmatched_returns +define dep_fetch_git-emqx + git clone -q --depth 1 -b $(call dep_commit,$(1)) -- $(call dep_repo,$(1)) $(DEPS_DIR)/$(call dep_name,$(1)) > /dev/null 2>&1; \ + cd $(DEPS_DIR)/$(call dep_name,$(1)); +endef + +core_http_get-emqx = curl -Lf$(if $(filter-out 0,$(V)),,s)o $(call core_native_path,$1) $2 + +define dep_fetch_hex-emqx + mkdir -p $(ERLANG_MK_TMP)/hex $(DEPS_DIR)/$1; \ + $(call core_http_get-emqx,$(ERLANG_MK_TMP)/hex/$1.tar,\ + https://repo.hex.pm/tarballs/$1-$(strip $(word 2,$(dep_$1))).tar); \ + tar -xOf $(ERLANG_MK_TMP)/hex/$1.tar contents.tar.gz | tar -C $(DEPS_DIR)/$1 -xzf -; +endef + include erlang.mk clean:: gen-clean rebar-clean @@ -119,7 +133,7 @@ comma = , quote = \" curly_l = "{" curly_r = "}" -dep-versions = [$(foreach dep,$(DEPS) $(BUILD_DEPS),$(curly_l)$(dep),$(quote)$(word 3,$(dep_$(dep)))$(quote)$(curly_r)$(comma))[]] +dep-versions = [$(foreach dep,$(DEPS) $(BUILD_DEPS),$(curly_l)$(dep),$(quote)$(word $(words $(dep_$(dep))),$(dep_$(dep)))$(quote)$(curly_r)$(comma))[]] .PHONY: dep-vsn-check dep-vsn-check: diff --git a/README.md b/README.md index f8872e8a0..8d03df8dd 100644 --- a/README.md +++ b/README.md @@ -63,6 +63,15 @@ You can reach the EMQ community and developers via the following channels: Please submit any bugs, issues, and feature requests to [emqx/emqx](https://github.com/emqx/emqx/issues). +## MQTT Specifications + +You can read the mqtt protocol via the following links: + +[MQTT Version 3.1.1](https://docs.oasis-open.org/mqtt/mqtt/v3.1.1/os/mqtt-v3.1.1-os.html) + +[MQTT Version 5.0](https://docs.oasis-open.org/mqtt/mqtt/v5.0/cs02/mqtt-v5.0-cs02.html) + +[MQTT SN](http://mqtt.org/new/wp-content/uploads/2009/06/MQTT-SN_spec_v1.2.pdf) ## License @@ -74,4 +83,3 @@ Licensed under the Apache License, Version 2.0 (the "License");you may not use t Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. - diff --git a/docs/.placeholder b/docs/.placeholder deleted file mode 100644 index e69de29bb..000000000 diff --git a/docs/MQTT-SN_spec_v1.2.pdf b/docs/MQTT-SN_spec_v1.2.pdf deleted file mode 100644 index ee6020d23..000000000 Binary files a/docs/MQTT-SN_spec_v1.2.pdf and /dev/null differ diff --git a/docs/README b/docs/README deleted file mode 100644 index 94f96fb12..000000000 --- a/docs/README +++ /dev/null @@ -1,11 +0,0 @@ - -http://emqttd.io/docs/v2/ - -or - -http://docs.emqtt.com/ - -or - -http://emqttd-docs.rtfd.org - diff --git a/docs/mqtt-v3.1.1.pdf b/docs/mqtt-v3.1.1.pdf deleted file mode 100644 index e4095f1b5..000000000 Binary files a/docs/mqtt-v3.1.1.pdf and /dev/null differ diff --git a/docs/mqtt-v5.0.pdf b/docs/mqtt-v5.0.pdf deleted file mode 100644 index c3d0c9725..000000000 Binary files a/docs/mqtt-v5.0.pdf and /dev/null differ diff --git a/rebar.config.script b/rebar.config.script index 0b18592f1..aed271af8 100644 --- a/rebar.config.script +++ b/rebar.config.script @@ -1,13 +1,21 @@ +CONFIG0 = case os:getenv("REBAR_GIT_CLONE_OPTIONS") of + "--depth 1" -> + CONFIG; + _ -> + os:putenv("REBAR_GIT_CLONE_OPTIONS", "--depth 1"), + CONFIG + end, + CONFIG1 = case os:getenv("TRAVIS") of - "true" -> - JobId = os:getenv("TRAVIS_JOB_ID"), - [{coveralls_service_job_id, JobId}, - {coveralls_coverdata, "_build/test/cover/*.coverdata"}, - {coveralls_service_name , "travis-ci"} | CONFIG]; - _ -> - CONFIG -end, + "true" -> + JobId = os:getenv("TRAVIS_JOB_ID"), + [{coveralls_service_job_id, JobId}, + {coveralls_coverdata, "_build/test/cover/*.coverdata"}, + {coveralls_service_name , "travis-ci"} | CONFIG]; + _ -> + CONFIG + end, {_, Deps} = lists:keyfind(deps, 1, CONFIG1), {_, OurDeps} = lists:keyfind(github_emqx_deps, 1, CONFIG1),