├── .gitignore ├── .jshintrc ├── .travis.yml ├── LICENSE ├── NOTICE ├── Procfile ├── README.md ├── api ├── api_suite_test.go ├── apifakes │ ├── fake_cluster_manager.go │ └── fake_response_writer.go ├── backends_index.go ├── backends_index_test.go ├── cluster.go ├── cluster_api.go ├── cluster_api_test.go ├── cluster_test.go ├── handler.go ├── handler_test.go └── middleware │ ├── basic_auth.go │ ├── chain.go │ ├── fakes │ ├── fake_logger.go │ └── fake_net_handler.go │ ├── https_enforcer.go │ ├── https_enforcer_test.go │ ├── logger.go │ ├── logger_test.go │ ├── middleware.go │ ├── middleware_suite_test.go │ └── panic_recovery.go ├── apiaggregator ├── apiaggregator_suite_test.go ├── handler.go └── handler_test.go ├── app ├── components │ ├── application.js │ ├── backend.js │ └── backends.js ├── images │ └── switchboard-header-logo.png └── stylesheets │ ├── _switchboard.styl │ └── application.styl ├── bin ├── build ├── build-ui ├── govet ├── regenerate-fakes ├── serve-ui ├── test ├── test-n-times └── test-ui ├── config ├── config.go ├── config_suite_test.go ├── config_test.go └── fixtures │ ├── emptyAPI.yml │ ├── emptyHealthPort.yml │ ├── emptyProxy.yml │ ├── invalidFields.yml │ └── validConfig.yml ├── domain ├── backend.go ├── backend_test.go ├── backends.go ├── bridge.go ├── bridge_test.go ├── bridges.go ├── bridges_test.go ├── domain_suite_test.go ├── domainfakes │ ├── fake_bridge.go │ ├── fake_bridges.go │ └── fake_net_conn.go └── messages.go ├── dummies ├── backend_runner.go └── healthcheck_runner.go ├── go.mod ├── go.sum ├── gulpfile.js ├── gulptasks.js ├── index.js ├── js-vendor └── pui-v1.4.0 │ ├── fonts │ ├── FontAwesome.otf │ ├── fontawesome-webfont.eot │ ├── fontawesome-webfont.svg │ ├── fontawesome-webfont.ttf │ ├── fontawesome-webfont.woff │ ├── sourcesanspro-black-webfont.eot │ ├── sourcesanspro-black-webfont.svg │ ├── sourcesanspro-black-webfont.ttf │ ├── sourcesanspro-black-webfont.woff │ ├── sourcesanspro-bold-webfont.eot │ ├── sourcesanspro-bold-webfont.svg │ ├── sourcesanspro-bold-webfont.ttf │ ├── sourcesanspro-bold-webfont.woff │ ├── sourcesanspro-extralight-webfont.eot │ ├── sourcesanspro-extralight-webfont.svg │ ├── sourcesanspro-extralight-webfont.ttf │ ├── sourcesanspro-extralight-webfont.woff │ ├── sourcesanspro-it-webfont.eot │ ├── sourcesanspro-it-webfont.svg │ ├── sourcesanspro-it-webfont.ttf │ ├── sourcesanspro-it-webfont.woff │ ├── sourcesanspro-light-webfont.eot │ ├── sourcesanspro-light-webfont.svg │ ├── sourcesanspro-light-webfont.ttf │ ├── sourcesanspro-light-webfont.woff │ ├── sourcesanspro-regular-webfont.eot │ ├── sourcesanspro-regular-webfont.svg │ ├── sourcesanspro-regular-webfont.ttf │ ├── sourcesanspro-regular-webfont.woff │ ├── sourcesanspro-semibold-webfont.eot │ ├── sourcesanspro-semibold-webfont.svg │ ├── sourcesanspro-semibold-webfont.ttf │ └── sourcesanspro-semibold-webfont.woff │ ├── images │ ├── aboutus-hero.jpg │ ├── console-laptop.png │ ├── favicon.ico │ ├── gray-cloud.png │ ├── img--examplesDebra.png │ ├── img--examplesGary.png │ ├── img--examplesKelly.png │ ├── img--examplesTodd.png │ ├── logo-pcf.png │ ├── logo-pws.png │ ├── logo.png │ ├── open-source-icon.png │ ├── p-logo.png │ ├── pivotal_footer_logo.png │ ├── pivotal_footer_logo@2x.png │ ├── pui-logo@2x.png │ ├── such-awesome.jpg │ └── we-care-sprites.png │ ├── pivotal-ui-rails.css │ ├── pivotal-ui-react.js │ ├── pivotal-ui-react.min.js │ ├── pivotal-ui.css │ ├── pivotal-ui.js │ ├── pivotal-ui.min.css │ └── pivotal-ui.min.js ├── main.go ├── main_suite_test.go ├── main_test.go ├── package.json ├── runner ├── api │ ├── api_suite_test.go │ ├── runner.go │ └── runner_test.go ├── apiaggregator │ ├── api_suite_test.go │ ├── runner.go │ └── runner_test.go ├── bridge │ ├── bridge_suite_test.go │ ├── runner.go │ └── runner_test.go ├── health │ ├── health_suite_test.go │ ├── runner.go │ └── runner_test.go └── monitor │ ├── cluster_monitor.go │ ├── cluster_monitor_test.go │ ├── decision_counters.go │ ├── monitor_suite_test.go │ ├── monitorfakes │ ├── fake_monitor.go │ └── fake_url_getter.go │ ├── runner.go │ └── runner_test.go ├── serve ├── components │ └── layout.js └── serve.js ├── spec └── app │ ├── components │ ├── application_spec.js │ ├── backend_spec.js │ └── backends_spec.js │ └── spec_helper.js ├── static ├── _switchboard.css ├── application.css ├── application.js ├── application.js.map ├── fonts │ ├── FontAwesome.otf │ ├── fontawesome-webfont.eot │ ├── fontawesome-webfont.svg │ ├── fontawesome-webfont.ttf │ ├── fontawesome-webfont.woff │ ├── sourcesanspro-black-webfont.eot │ ├── sourcesanspro-black-webfont.svg │ ├── sourcesanspro-black-webfont.ttf │ ├── sourcesanspro-black-webfont.woff │ ├── sourcesanspro-bold-webfont.eot │ ├── sourcesanspro-bold-webfont.svg │ ├── sourcesanspro-bold-webfont.ttf │ ├── sourcesanspro-bold-webfont.woff │ ├── sourcesanspro-extralight-webfont.eot │ ├── sourcesanspro-extralight-webfont.svg │ ├── sourcesanspro-extralight-webfont.ttf │ ├── sourcesanspro-extralight-webfont.woff │ ├── sourcesanspro-it-webfont.eot │ ├── sourcesanspro-it-webfont.svg │ ├── sourcesanspro-it-webfont.ttf │ ├── sourcesanspro-it-webfont.woff │ ├── sourcesanspro-light-webfont.eot │ ├── sourcesanspro-light-webfont.svg │ ├── sourcesanspro-light-webfont.ttf │ ├── sourcesanspro-light-webfont.woff │ ├── sourcesanspro-regular-webfont.eot │ ├── sourcesanspro-regular-webfont.svg │ ├── sourcesanspro-regular-webfont.ttf │ ├── sourcesanspro-regular-webfont.woff │ ├── sourcesanspro-semibold-webfont.eot │ ├── sourcesanspro-semibold-webfont.svg │ ├── sourcesanspro-semibold-webfont.ttf │ └── sourcesanspro-semibold-webfont.woff ├── images │ ├── aboutus-hero.jpg │ ├── console-laptop.png │ ├── favicon.ico │ ├── gray-cloud.png │ ├── img--examplesDebra.png │ ├── img--examplesGary.png │ ├── img--examplesKelly.png │ ├── img--examplesTodd.png │ ├── logo-pcf.png │ ├── logo-pws.png │ ├── logo.png │ ├── open-source-icon.png │ ├── p-logo.png │ ├── pivotal_footer_logo.png │ ├── pivotal_footer_logo@2x.png │ ├── pui-logo@2x.png │ ├── such-awesome.jpg │ └── we-care-sprites.png ├── index.html ├── pivotal-ui-rails.css ├── pivotal-ui-react.js ├── pivotal-ui-react.min.js ├── pivotal-ui.css ├── pivotal-ui.js ├── pivotal-ui.min.css ├── pivotal-ui.min.js └── switchboard-header-logo.png ├── tools └── tools.go └── vendor ├── code.cloudfoundry.org └── lager │ ├── LICENSE │ ├── NOTICE │ ├── README.md │ ├── json_redacter.go │ ├── lagerctx │ ├── context.go │ └── package.go │ ├── lagerflags │ ├── LICENSE │ ├── NOTICE │ ├── README.md │ ├── lagerflags.go │ └── package.go │ ├── lagertest │ ├── package.go │ └── test_sink.go │ ├── logger.go │ ├── models.go │ ├── package.go │ ├── reconfigurable_sink.go │ ├── redacting_sink.go │ └── writer_sink.go ├── github.com ├── bmizerany │ └── pat │ │ ├── .gitignore │ │ ├── LICENSE │ │ ├── README.md │ │ └── mux.go ├── cloudfoundry-incubator │ └── galera-healthcheck │ │ ├── LICENSE │ │ ├── NOTICE │ │ ├── api │ │ ├── api.go │ │ └── middleware │ │ │ ├── basic_auth.go │ │ │ └── middleware.go │ │ ├── config │ │ └── config.go │ │ └── domain │ │ └── db_state.go ├── fsnotify │ └── fsnotify │ │ ├── .editorconfig │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── .mailmap │ │ ├── AUTHORS │ │ ├── CHANGELOG.md │ │ ├── CONTRIBUTING.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── fen.go │ │ ├── fsnotify.go │ │ ├── go.mod │ │ ├── go.sum │ │ ├── inotify.go │ │ ├── inotify_poller.go │ │ ├── kqueue.go │ │ ├── open_mode_bsd.go │ │ ├── open_mode_darwin.go │ │ └── windows.go ├── go-task │ └── slim-sprig │ │ ├── .editorconfig │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── CHANGELOG.md │ │ ├── LICENSE.txt │ │ ├── README.md │ │ ├── Taskfile.yml │ │ ├── crypto.go │ │ ├── date.go │ │ ├── defaults.go │ │ ├── dict.go │ │ ├── doc.go │ │ ├── functions.go │ │ ├── go.mod │ │ ├── go.sum │ │ ├── list.go │ │ ├── network.go │ │ ├── numeric.go │ │ ├── reflect.go │ │ ├── regex.go │ │ ├── strings.go │ │ └── url.go ├── golang │ └── protobuf │ │ ├── AUTHORS │ │ ├── CONTRIBUTORS │ │ ├── LICENSE │ │ └── proto │ │ ├── buffer.go │ │ ├── defaults.go │ │ ├── deprecated.go │ │ ├── discard.go │ │ ├── extensions.go │ │ ├── properties.go │ │ ├── proto.go │ │ ├── registry.go │ │ ├── text_decode.go │ │ ├── text_encode.go │ │ ├── wire.go │ │ └── wrappers.go ├── imdario │ └── mergo │ │ ├── .deepsource.toml │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── CODE_OF_CONDUCT.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── doc.go │ │ ├── go.mod │ │ ├── go.sum │ │ ├── map.go │ │ ├── merge.go │ │ └── mergo.go ├── maxbrunsfeld │ └── counterfeiter │ │ └── v6 │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── appveyor.yml │ │ ├── arguments │ │ ├── files.go │ │ ├── parser.go │ │ └── usage.go │ │ ├── command │ │ └── runner.go │ │ ├── generator │ │ ├── cache.go │ │ ├── fake.go │ │ ├── function_loader.go │ │ ├── function_template.go │ │ ├── import.go │ │ ├── interface_loader.go │ │ ├── interface_template.go │ │ ├── loader.go │ │ ├── package_loader.go │ │ ├── package_template.go │ │ ├── param.go │ │ └── return.go │ │ ├── go.mod │ │ ├── go.sum │ │ └── main.go ├── nxadm │ └── tail │ │ ├── .gitignore │ │ ├── CHANGES.md │ │ ├── Dockerfile │ │ ├── LICENSE │ │ ├── README.md │ │ ├── go.mod │ │ ├── go.sum │ │ ├── ratelimiter │ │ ├── Licence │ │ ├── leakybucket.go │ │ ├── memory.go │ │ └── storage.go │ │ ├── tail.go │ │ ├── tail_posix.go │ │ ├── tail_windows.go │ │ ├── util │ │ └── util.go │ │ ├── watch │ │ ├── filechanges.go │ │ ├── inotify.go │ │ ├── inotify_tracker.go │ │ ├── polling.go │ │ └── watch.go │ │ └── winfile │ │ └── winfile.go ├── onsi │ ├── ginkgo │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── CHANGELOG.md │ │ ├── CONTRIBUTING.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── RELEASING.md │ │ ├── config │ │ │ └── config.go │ │ ├── formatter │ │ │ └── formatter.go │ │ ├── ginkgo │ │ │ ├── bootstrap_command.go │ │ │ ├── build_command.go │ │ │ ├── convert │ │ │ │ ├── ginkgo_ast_nodes.go │ │ │ │ ├── import.go │ │ │ │ ├── package_rewriter.go │ │ │ │ ├── test_finder.go │ │ │ │ ├── testfile_rewriter.go │ │ │ │ └── testing_t_rewriter.go │ │ │ ├── convert_command.go │ │ │ ├── generate_command.go │ │ │ ├── help_command.go │ │ │ ├── interrupthandler │ │ │ │ ├── interrupt_handler.go │ │ │ │ ├── sigquit_swallower_unix.go │ │ │ │ └── sigquit_swallower_windows.go │ │ │ ├── main.go │ │ │ ├── nodot │ │ │ │ └── nodot.go │ │ │ ├── nodot_command.go │ │ │ ├── notifications.go │ │ │ ├── outline │ │ │ │ ├── ginkgo.go │ │ │ │ ├── import.go │ │ │ │ └── outline.go │ │ │ ├── outline_command.go │ │ │ ├── run_command.go │ │ │ ├── run_watch_and_build_command_flags.go │ │ │ ├── suite_runner.go │ │ │ ├── testrunner │ │ │ │ ├── build_args.go │ │ │ │ ├── build_args_old.go │ │ │ │ ├── log_writer.go │ │ │ │ ├── run_result.go │ │ │ │ └── test_runner.go │ │ │ ├── testsuite │ │ │ │ ├── test_suite.go │ │ │ │ ├── vendor_check_go15.go │ │ │ │ └── vendor_check_go16.go │ │ │ ├── unfocus_command.go │ │ │ ├── version_command.go │ │ │ ├── watch │ │ │ │ ├── delta.go │ │ │ │ ├── delta_tracker.go │ │ │ │ ├── dependencies.go │ │ │ │ ├── package_hash.go │ │ │ │ ├── package_hashes.go │ │ │ │ └── suite.go │ │ │ └── watch_command.go │ │ ├── ginkgo_dsl.go │ │ ├── go.mod │ │ ├── go.sum │ │ ├── internal │ │ │ ├── codelocation │ │ │ │ └── code_location.go │ │ │ ├── containernode │ │ │ │ └── container_node.go │ │ │ ├── failer │ │ │ │ └── failer.go │ │ │ ├── global │ │ │ │ └── init.go │ │ │ ├── leafnodes │ │ │ │ ├── benchmarker.go │ │ │ │ ├── interfaces.go │ │ │ │ ├── it_node.go │ │ │ │ ├── measure_node.go │ │ │ │ ├── runner.go │ │ │ │ ├── setup_nodes.go │ │ │ │ ├── suite_nodes.go │ │ │ │ ├── synchronized_after_suite_node.go │ │ │ │ └── synchronized_before_suite_node.go │ │ │ ├── remote │ │ │ │ ├── aggregator.go │ │ │ │ ├── forwarding_reporter.go │ │ │ │ ├── output_interceptor.go │ │ │ │ ├── output_interceptor_unix.go │ │ │ │ ├── output_interceptor_win.go │ │ │ │ └── server.go │ │ │ ├── spec │ │ │ │ ├── spec.go │ │ │ │ └── specs.go │ │ │ ├── spec_iterator │ │ │ │ ├── index_computer.go │ │ │ │ ├── parallel_spec_iterator.go │ │ │ │ ├── serial_spec_iterator.go │ │ │ │ ├── sharded_parallel_spec_iterator.go │ │ │ │ └── spec_iterator.go │ │ │ ├── specrunner │ │ │ │ ├── random_id.go │ │ │ │ └── spec_runner.go │ │ │ ├── suite │ │ │ │ └── suite.go │ │ │ ├── testingtproxy │ │ │ │ └── testing_t_proxy.go │ │ │ └── writer │ │ │ │ ├── fake_writer.go │ │ │ │ └── writer.go │ │ ├── reporters │ │ │ ├── default_reporter.go │ │ │ ├── fake_reporter.go │ │ │ ├── junit_reporter.go │ │ │ ├── reporter.go │ │ │ ├── stenographer │ │ │ │ ├── console_logging.go │ │ │ │ ├── fake_stenographer.go │ │ │ │ ├── stenographer.go │ │ │ │ └── support │ │ │ │ │ ├── go-colorable │ │ │ │ │ ├── LICENSE │ │ │ │ │ ├── README.md │ │ │ │ │ ├── colorable_others.go │ │ │ │ │ ├── colorable_windows.go │ │ │ │ │ └── noncolorable.go │ │ │ │ │ └── go-isatty │ │ │ │ │ ├── LICENSE │ │ │ │ │ ├── README.md │ │ │ │ │ ├── doc.go │ │ │ │ │ ├── isatty_appengine.go │ │ │ │ │ ├── isatty_bsd.go │ │ │ │ │ ├── isatty_linux.go │ │ │ │ │ ├── isatty_solaris.go │ │ │ │ │ └── isatty_windows.go │ │ │ └── teamcity_reporter.go │ │ └── types │ │ │ ├── code_location.go │ │ │ ├── deprecation_support.go │ │ │ ├── synchronization.go │ │ │ └── types.go │ └── gomega │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── CHANGELOG.md │ │ ├── CONTRIBUTING.md │ │ ├── Dockerfile │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── RELEASING.md │ │ ├── docker-compose.yaml │ │ ├── format │ │ └── format.go │ │ ├── gbytes │ │ ├── buffer.go │ │ ├── io_wrappers.go │ │ └── say_matcher.go │ │ ├── gexec │ │ ├── build.go │ │ ├── exit_matcher.go │ │ ├── prefixed_writer.go │ │ └── session.go │ │ ├── ghttp │ │ ├── handlers.go │ │ └── test_server.go │ │ ├── go.mod │ │ ├── go.sum │ │ ├── gomega_dsl.go │ │ ├── internal │ │ ├── assertion.go │ │ ├── async_assertion.go │ │ ├── duration_bundle.go │ │ └── gomega.go │ │ ├── matchers.go │ │ ├── matchers │ │ ├── and.go │ │ ├── assignable_to_type_of_matcher.go │ │ ├── attributes_slice.go │ │ ├── be_a_directory.go │ │ ├── be_a_regular_file.go │ │ ├── be_an_existing_file.go │ │ ├── be_closed_matcher.go │ │ ├── be_element_of_matcher.go │ │ ├── be_empty_matcher.go │ │ ├── be_equivalent_to_matcher.go │ │ ├── be_false_matcher.go │ │ ├── be_identical_to.go │ │ ├── be_nil_matcher.go │ │ ├── be_numerically_matcher.go │ │ ├── be_sent_matcher.go │ │ ├── be_temporally_matcher.go │ │ ├── be_true_matcher.go │ │ ├── be_zero_matcher.go │ │ ├── consist_of.go │ │ ├── contain_element_matcher.go │ │ ├── contain_elements_matcher.go │ │ ├── contain_substring_matcher.go │ │ ├── equal_matcher.go │ │ ├── have_cap_matcher.go │ │ ├── have_http_body_matcher.go │ │ ├── have_http_header_with_value_matcher.go │ │ ├── have_http_status_matcher.go │ │ ├── have_key_matcher.go │ │ ├── have_key_with_value_matcher.go │ │ ├── have_len_matcher.go │ │ ├── have_occurred_matcher.go │ │ ├── have_prefix_matcher.go │ │ ├── have_suffix_matcher.go │ │ ├── match_error_matcher.go │ │ ├── match_json_matcher.go │ │ ├── match_regexp_matcher.go │ │ ├── match_xml_matcher.go │ │ ├── match_yaml_matcher.go │ │ ├── not.go │ │ ├── or.go │ │ ├── panic_matcher.go │ │ ├── receive_matcher.go │ │ ├── satisfy_matcher.go │ │ ├── semi_structured_data_support.go │ │ ├── succeed_matcher.go │ │ ├── support │ │ │ └── goraph │ │ │ │ ├── bipartitegraph │ │ │ │ ├── bipartitegraph.go │ │ │ │ └── bipartitegraphmatching.go │ │ │ │ ├── edge │ │ │ │ └── edge.go │ │ │ │ ├── node │ │ │ │ └── node.go │ │ │ │ └── util │ │ │ │ └── util.go │ │ ├── type_support.go │ │ └── with_transform.go │ │ └── types │ │ └── types.go ├── pivotal-cf-experimental │ └── service-config │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── config.go │ │ ├── config_reader.go │ │ └── test_helpers │ │ └── test_helpers.go └── tedsuo │ ├── ifrit │ ├── .gitignore │ ├── LICENSE │ ├── README.md │ ├── doc.go │ ├── ginkgomon │ │ ├── ginkgomon.go │ │ └── helpers.go │ ├── grouper │ │ ├── client.go │ │ ├── doc.go │ │ ├── dynamic_group.go │ │ ├── entrance_events.go │ │ ├── exit_events.go │ │ ├── members.go │ │ ├── ordered.go │ │ ├── parallel.go │ │ ├── queue_ordered.go │ │ └── sliding_buffer.go │ ├── http_server │ │ └── http_server.go │ ├── process.go │ ├── runner.go │ └── sigmon │ │ └── sigmon.go │ └── rata │ ├── LICENSE │ ├── README.md │ ├── VERSION │ ├── docs.go │ ├── param.go │ ├── requests.go │ ├── router.go │ └── routes.go ├── golang.org └── x │ ├── mod │ ├── LICENSE │ ├── PATENTS │ ├── module │ │ └── module.go │ └── semver │ │ └── semver.go │ ├── net │ ├── AUTHORS │ ├── CONTRIBUTORS │ ├── LICENSE │ ├── PATENTS │ └── html │ │ ├── atom │ │ ├── atom.go │ │ └── table.go │ │ ├── charset │ │ └── charset.go │ │ ├── const.go │ │ ├── doc.go │ │ ├── doctype.go │ │ ├── entity.go │ │ ├── escape.go │ │ ├── foreign.go │ │ ├── node.go │ │ ├── parse.go │ │ ├── render.go │ │ └── token.go │ ├── sys │ ├── AUTHORS │ ├── CONTRIBUTORS │ ├── LICENSE │ ├── PATENTS │ ├── internal │ │ └── unsafeheader │ │ │ └── unsafeheader.go │ └── unix │ │ ├── .gitignore │ │ ├── README.md │ │ ├── affinity_linux.go │ │ ├── aliases.go │ │ ├── asm_aix_ppc64.s │ │ ├── asm_bsd_386.s │ │ ├── asm_bsd_amd64.s │ │ ├── asm_bsd_arm.s │ │ ├── asm_bsd_arm64.s │ │ ├── asm_linux_386.s │ │ ├── asm_linux_amd64.s │ │ ├── asm_linux_arm.s │ │ ├── asm_linux_arm64.s │ │ ├── asm_linux_mips64x.s │ │ ├── asm_linux_mipsx.s │ │ ├── asm_linux_ppc64x.s │ │ ├── asm_linux_riscv64.s │ │ ├── asm_linux_s390x.s │ │ ├── asm_openbsd_mips64.s │ │ ├── asm_solaris_amd64.s │ │ ├── asm_zos_s390x.s │ │ ├── bluetooth_linux.go │ │ ├── cap_freebsd.go │ │ ├── constants.go │ │ ├── dev_aix_ppc.go │ │ ├── dev_aix_ppc64.go │ │ ├── dev_darwin.go │ │ ├── dev_dragonfly.go │ │ ├── dev_freebsd.go │ │ ├── dev_linux.go │ │ ├── dev_netbsd.go │ │ ├── dev_openbsd.go │ │ ├── dev_zos.go │ │ ├── dirent.go │ │ ├── endian_big.go │ │ ├── endian_little.go │ │ ├── env_unix.go │ │ ├── epoll_zos.go │ │ ├── errors_freebsd_386.go │ │ ├── errors_freebsd_amd64.go │ │ ├── errors_freebsd_arm.go │ │ ├── errors_freebsd_arm64.go │ │ ├── fcntl.go │ │ ├── fcntl_darwin.go │ │ ├── fcntl_linux_32bit.go │ │ ├── fdset.go │ │ ├── fstatfs_zos.go │ │ ├── gccgo.go │ │ ├── gccgo_c.c │ │ ├── gccgo_linux_amd64.go │ │ ├── ifreq_linux.go │ │ ├── ioctl.go │ │ ├── ioctl_linux.go │ │ ├── ioctl_zos.go │ │ ├── mkall.sh │ │ ├── mkerrors.sh │ │ ├── pagesize_unix.go │ │ ├── pledge_openbsd.go │ │ ├── ptrace_darwin.go │ │ ├── ptrace_ios.go │ │ ├── race.go │ │ ├── race0.go │ │ ├── readdirent_getdents.go │ │ ├── readdirent_getdirentries.go │ │ ├── sockcmsg_dragonfly.go │ │ ├── sockcmsg_linux.go │ │ ├── sockcmsg_unix.go │ │ ├── sockcmsg_unix_other.go │ │ ├── str.go │ │ ├── syscall.go │ │ ├── syscall_aix.go │ │ ├── syscall_aix_ppc.go │ │ ├── syscall_aix_ppc64.go │ │ ├── syscall_bsd.go │ │ ├── syscall_darwin.1_12.go │ │ ├── syscall_darwin.1_13.go │ │ ├── syscall_darwin.go │ │ ├── syscall_darwin_amd64.go │ │ ├── syscall_darwin_arm64.go │ │ ├── syscall_darwin_libSystem.go │ │ ├── syscall_dragonfly.go │ │ ├── syscall_dragonfly_amd64.go │ │ ├── syscall_freebsd.go │ │ ├── syscall_freebsd_386.go │ │ ├── syscall_freebsd_amd64.go │ │ ├── syscall_freebsd_arm.go │ │ ├── syscall_freebsd_arm64.go │ │ ├── syscall_illumos.go │ │ ├── syscall_linux.go │ │ ├── syscall_linux_386.go │ │ ├── syscall_linux_amd64.go │ │ ├── syscall_linux_amd64_gc.go │ │ ├── syscall_linux_arm.go │ │ ├── syscall_linux_arm64.go │ │ ├── syscall_linux_gc.go │ │ ├── syscall_linux_gc_386.go │ │ ├── syscall_linux_gc_arm.go │ │ ├── syscall_linux_gccgo_386.go │ │ ├── syscall_linux_gccgo_arm.go │ │ ├── syscall_linux_mips64x.go │ │ ├── syscall_linux_mipsx.go │ │ ├── syscall_linux_ppc.go │ │ ├── syscall_linux_ppc64x.go │ │ ├── syscall_linux_riscv64.go │ │ ├── syscall_linux_s390x.go │ │ ├── syscall_linux_sparc64.go │ │ ├── syscall_netbsd.go │ │ ├── syscall_netbsd_386.go │ │ ├── syscall_netbsd_amd64.go │ │ ├── syscall_netbsd_arm.go │ │ ├── syscall_netbsd_arm64.go │ │ ├── syscall_openbsd.go │ │ ├── syscall_openbsd_386.go │ │ ├── syscall_openbsd_amd64.go │ │ ├── syscall_openbsd_arm.go │ │ ├── syscall_openbsd_arm64.go │ │ ├── syscall_openbsd_mips64.go │ │ ├── syscall_solaris.go │ │ ├── syscall_solaris_amd64.go │ │ ├── syscall_unix.go │ │ ├── syscall_unix_gc.go │ │ ├── syscall_unix_gc_ppc64x.go │ │ ├── syscall_zos_s390x.go │ │ ├── timestruct.go │ │ ├── unveil_openbsd.go │ │ ├── xattr_bsd.go │ │ ├── zerrors_aix_ppc.go │ │ ├── zerrors_aix_ppc64.go │ │ ├── zerrors_darwin_amd64.go │ │ ├── zerrors_darwin_arm64.go │ │ ├── zerrors_dragonfly_amd64.go │ │ ├── zerrors_freebsd_386.go │ │ ├── zerrors_freebsd_amd64.go │ │ ├── zerrors_freebsd_arm.go │ │ ├── zerrors_freebsd_arm64.go │ │ ├── zerrors_linux.go │ │ ├── zerrors_linux_386.go │ │ ├── zerrors_linux_amd64.go │ │ ├── zerrors_linux_arm.go │ │ ├── zerrors_linux_arm64.go │ │ ├── zerrors_linux_mips.go │ │ ├── zerrors_linux_mips64.go │ │ ├── zerrors_linux_mips64le.go │ │ ├── zerrors_linux_mipsle.go │ │ ├── zerrors_linux_ppc.go │ │ ├── zerrors_linux_ppc64.go │ │ ├── zerrors_linux_ppc64le.go │ │ ├── zerrors_linux_riscv64.go │ │ ├── zerrors_linux_s390x.go │ │ ├── zerrors_linux_sparc64.go │ │ ├── zerrors_netbsd_386.go │ │ ├── zerrors_netbsd_amd64.go │ │ ├── zerrors_netbsd_arm.go │ │ ├── zerrors_netbsd_arm64.go │ │ ├── zerrors_openbsd_386.go │ │ ├── zerrors_openbsd_amd64.go │ │ ├── zerrors_openbsd_arm.go │ │ ├── zerrors_openbsd_arm64.go │ │ ├── zerrors_openbsd_mips64.go │ │ ├── zerrors_solaris_amd64.go │ │ ├── zerrors_zos_s390x.go │ │ ├── zptrace_armnn_linux.go │ │ ├── zptrace_linux_arm64.go │ │ ├── zptrace_mipsnn_linux.go │ │ ├── zptrace_mipsnnle_linux.go │ │ ├── zptrace_x86_linux.go │ │ ├── zsyscall_aix_ppc.go │ │ ├── zsyscall_aix_ppc64.go │ │ ├── zsyscall_aix_ppc64_gc.go │ │ ├── zsyscall_aix_ppc64_gccgo.go │ │ ├── zsyscall_darwin_amd64.1_13.go │ │ ├── zsyscall_darwin_amd64.1_13.s │ │ ├── zsyscall_darwin_amd64.go │ │ ├── zsyscall_darwin_amd64.s │ │ ├── zsyscall_darwin_arm64.1_13.go │ │ ├── zsyscall_darwin_arm64.1_13.s │ │ ├── zsyscall_darwin_arm64.go │ │ ├── zsyscall_darwin_arm64.s │ │ ├── zsyscall_dragonfly_amd64.go │ │ ├── zsyscall_freebsd_386.go │ │ ├── zsyscall_freebsd_amd64.go │ │ ├── zsyscall_freebsd_arm.go │ │ ├── zsyscall_freebsd_arm64.go │ │ ├── zsyscall_illumos_amd64.go │ │ ├── zsyscall_linux.go │ │ ├── zsyscall_linux_386.go │ │ ├── zsyscall_linux_amd64.go │ │ ├── zsyscall_linux_arm.go │ │ ├── zsyscall_linux_arm64.go │ │ ├── zsyscall_linux_mips.go │ │ ├── zsyscall_linux_mips64.go │ │ ├── zsyscall_linux_mips64le.go │ │ ├── zsyscall_linux_mipsle.go │ │ ├── zsyscall_linux_ppc.go │ │ ├── zsyscall_linux_ppc64.go │ │ ├── zsyscall_linux_ppc64le.go │ │ ├── zsyscall_linux_riscv64.go │ │ ├── zsyscall_linux_s390x.go │ │ ├── zsyscall_linux_sparc64.go │ │ ├── zsyscall_netbsd_386.go │ │ ├── zsyscall_netbsd_amd64.go │ │ ├── zsyscall_netbsd_arm.go │ │ ├── zsyscall_netbsd_arm64.go │ │ ├── zsyscall_openbsd_386.go │ │ ├── zsyscall_openbsd_amd64.go │ │ ├── zsyscall_openbsd_arm.go │ │ ├── zsyscall_openbsd_arm64.go │ │ ├── zsyscall_openbsd_mips64.go │ │ ├── zsyscall_solaris_amd64.go │ │ ├── zsyscall_zos_s390x.go │ │ ├── zsysctl_openbsd_386.go │ │ ├── zsysctl_openbsd_amd64.go │ │ ├── zsysctl_openbsd_arm.go │ │ ├── zsysctl_openbsd_arm64.go │ │ ├── zsysctl_openbsd_mips64.go │ │ ├── zsysnum_darwin_amd64.go │ │ ├── zsysnum_darwin_arm64.go │ │ ├── zsysnum_dragonfly_amd64.go │ │ ├── zsysnum_freebsd_386.go │ │ ├── zsysnum_freebsd_amd64.go │ │ ├── zsysnum_freebsd_arm.go │ │ ├── zsysnum_freebsd_arm64.go │ │ ├── zsysnum_linux_386.go │ │ ├── zsysnum_linux_amd64.go │ │ ├── zsysnum_linux_arm.go │ │ ├── zsysnum_linux_arm64.go │ │ ├── zsysnum_linux_mips.go │ │ ├── zsysnum_linux_mips64.go │ │ ├── zsysnum_linux_mips64le.go │ │ ├── zsysnum_linux_mipsle.go │ │ ├── zsysnum_linux_ppc.go │ │ ├── zsysnum_linux_ppc64.go │ │ ├── zsysnum_linux_ppc64le.go │ │ ├── zsysnum_linux_riscv64.go │ │ ├── zsysnum_linux_s390x.go │ │ ├── zsysnum_linux_sparc64.go │ │ ├── zsysnum_netbsd_386.go │ │ ├── zsysnum_netbsd_amd64.go │ │ ├── zsysnum_netbsd_arm.go │ │ ├── zsysnum_netbsd_arm64.go │ │ ├── zsysnum_openbsd_386.go │ │ ├── zsysnum_openbsd_amd64.go │ │ ├── zsysnum_openbsd_arm.go │ │ ├── zsysnum_openbsd_arm64.go │ │ ├── zsysnum_openbsd_mips64.go │ │ ├── zsysnum_zos_s390x.go │ │ ├── ztypes_aix_ppc.go │ │ ├── ztypes_aix_ppc64.go │ │ ├── ztypes_darwin_amd64.go │ │ ├── ztypes_darwin_arm64.go │ │ ├── ztypes_dragonfly_amd64.go │ │ ├── ztypes_freebsd_386.go │ │ ├── ztypes_freebsd_amd64.go │ │ ├── ztypes_freebsd_arm.go │ │ ├── ztypes_freebsd_arm64.go │ │ ├── ztypes_illumos_amd64.go │ │ ├── ztypes_linux.go │ │ ├── ztypes_linux_386.go │ │ ├── ztypes_linux_amd64.go │ │ ├── ztypes_linux_arm.go │ │ ├── ztypes_linux_arm64.go │ │ ├── ztypes_linux_mips.go │ │ ├── ztypes_linux_mips64.go │ │ ├── ztypes_linux_mips64le.go │ │ ├── ztypes_linux_mipsle.go │ │ ├── ztypes_linux_ppc.go │ │ ├── ztypes_linux_ppc64.go │ │ ├── ztypes_linux_ppc64le.go │ │ ├── ztypes_linux_riscv64.go │ │ ├── ztypes_linux_s390x.go │ │ ├── ztypes_linux_sparc64.go │ │ ├── ztypes_netbsd_386.go │ │ ├── ztypes_netbsd_amd64.go │ │ ├── ztypes_netbsd_arm.go │ │ ├── ztypes_netbsd_arm64.go │ │ ├── ztypes_openbsd_386.go │ │ ├── ztypes_openbsd_amd64.go │ │ ├── ztypes_openbsd_arm.go │ │ ├── ztypes_openbsd_arm64.go │ │ ├── ztypes_openbsd_mips64.go │ │ ├── ztypes_solaris_amd64.go │ │ └── ztypes_zos_s390x.go │ ├── text │ ├── AUTHORS │ ├── CONTRIBUTORS │ ├── LICENSE │ ├── PATENTS │ ├── encoding │ │ ├── charmap │ │ │ ├── charmap.go │ │ │ └── tables.go │ │ ├── encoding.go │ │ ├── htmlindex │ │ │ ├── htmlindex.go │ │ │ ├── map.go │ │ │ └── tables.go │ │ ├── internal │ │ │ ├── identifier │ │ │ │ ├── identifier.go │ │ │ │ └── mib.go │ │ │ └── internal.go │ │ ├── japanese │ │ │ ├── all.go │ │ │ ├── eucjp.go │ │ │ ├── iso2022jp.go │ │ │ ├── shiftjis.go │ │ │ └── tables.go │ │ ├── korean │ │ │ ├── euckr.go │ │ │ └── tables.go │ │ ├── simplifiedchinese │ │ │ ├── all.go │ │ │ ├── gbk.go │ │ │ ├── hzgb2312.go │ │ │ └── tables.go │ │ ├── traditionalchinese │ │ │ ├── big5.go │ │ │ └── tables.go │ │ └── unicode │ │ │ ├── override.go │ │ │ └── unicode.go │ ├── internal │ │ ├── language │ │ │ ├── common.go │ │ │ ├── compact.go │ │ │ ├── compact │ │ │ │ ├── compact.go │ │ │ │ ├── language.go │ │ │ │ ├── parents.go │ │ │ │ ├── tables.go │ │ │ │ └── tags.go │ │ │ ├── compose.go │ │ │ ├── coverage.go │ │ │ ├── language.go │ │ │ ├── lookup.go │ │ │ ├── match.go │ │ │ ├── parse.go │ │ │ ├── tables.go │ │ │ └── tags.go │ │ ├── tag │ │ │ └── tag.go │ │ └── utf8internal │ │ │ └── utf8internal.go │ ├── language │ │ ├── coverage.go │ │ ├── doc.go │ │ ├── go1_1.go │ │ ├── go1_2.go │ │ ├── language.go │ │ ├── match.go │ │ ├── parse.go │ │ ├── tables.go │ │ └── tags.go │ ├── runes │ │ ├── cond.go │ │ └── runes.go │ └── transform │ │ └── transform.go │ ├── tools │ ├── AUTHORS │ ├── CONTRIBUTORS │ ├── LICENSE │ ├── PATENTS │ ├── go │ │ ├── ast │ │ │ ├── astutil │ │ │ │ ├── enclosing.go │ │ │ │ ├── imports.go │ │ │ │ ├── rewrite.go │ │ │ │ └── util.go │ │ │ └── inspector │ │ │ │ ├── inspector.go │ │ │ │ └── typeof.go │ │ ├── gcexportdata │ │ │ ├── gcexportdata.go │ │ │ └── importer.go │ │ ├── internal │ │ │ ├── gcimporter │ │ │ │ ├── bexport.go │ │ │ │ ├── bimport.go │ │ │ │ ├── exportdata.go │ │ │ │ ├── gcimporter.go │ │ │ │ ├── iexport.go │ │ │ │ ├── iimport.go │ │ │ │ ├── newInterface10.go │ │ │ │ └── newInterface11.go │ │ │ └── packagesdriver │ │ │ │ └── sizes.go │ │ ├── packages │ │ │ ├── doc.go │ │ │ ├── external.go │ │ │ ├── golist.go │ │ │ ├── golist_overlay.go │ │ │ ├── loadmode_string.go │ │ │ ├── packages.go │ │ │ └── visit.go │ │ └── types │ │ │ └── typeutil │ │ │ ├── callee.go │ │ │ ├── imports.go │ │ │ ├── map.go │ │ │ ├── methodsetcache.go │ │ │ └── ui.go │ ├── imports │ │ └── forward.go │ └── internal │ │ ├── event │ │ ├── core │ │ │ ├── event.go │ │ │ ├── export.go │ │ │ └── fast.go │ │ ├── doc.go │ │ ├── event.go │ │ ├── keys │ │ │ ├── keys.go │ │ │ └── standard.go │ │ └── label │ │ │ └── label.go │ │ ├── fastwalk │ │ ├── fastwalk.go │ │ ├── fastwalk_dirent_fileno.go │ │ ├── fastwalk_dirent_ino.go │ │ ├── fastwalk_dirent_namlen_bsd.go │ │ ├── fastwalk_dirent_namlen_linux.go │ │ ├── fastwalk_portable.go │ │ └── fastwalk_unix.go │ │ ├── gocommand │ │ ├── invoke.go │ │ ├── vendor.go │ │ └── version.go │ │ ├── gopathwalk │ │ └── walk.go │ │ ├── imports │ │ ├── fix.go │ │ ├── imports.go │ │ ├── mod.go │ │ ├── mod_cache.go │ │ ├── sortimports.go │ │ └── zstdlib.go │ │ ├── packagesinternal │ │ └── packages.go │ │ └── typesinternal │ │ ├── errorcode.go │ │ ├── errorcode_string.go │ │ └── types.go │ └── xerrors │ ├── LICENSE │ ├── PATENTS │ ├── README │ ├── adaptor.go │ ├── codereview.cfg │ ├── doc.go │ ├── errors.go │ ├── fmt.go │ ├── format.go │ ├── frame.go │ ├── go.mod │ ├── internal │ └── internal.go │ └── wrap.go ├── google.golang.org └── protobuf │ ├── AUTHORS │ ├── CONTRIBUTORS │ ├── LICENSE │ ├── PATENTS │ ├── encoding │ ├── prototext │ │ ├── decode.go │ │ ├── doc.go │ │ └── encode.go │ └── protowire │ │ └── wire.go │ ├── internal │ ├── descfmt │ │ └── stringer.go │ ├── descopts │ │ └── options.go │ ├── detrand │ │ └── rand.go │ ├── encoding │ │ ├── defval │ │ │ └── default.go │ │ ├── messageset │ │ │ └── messageset.go │ │ ├── tag │ │ │ └── tag.go │ │ └── text │ │ │ ├── decode.go │ │ │ ├── decode_number.go │ │ │ ├── decode_string.go │ │ │ ├── decode_token.go │ │ │ ├── doc.go │ │ │ └── encode.go │ ├── errors │ │ ├── errors.go │ │ ├── is_go112.go │ │ └── is_go113.go │ ├── filedesc │ │ ├── build.go │ │ ├── desc.go │ │ ├── desc_init.go │ │ ├── desc_lazy.go │ │ ├── desc_list.go │ │ ├── desc_list_gen.go │ │ └── placeholder.go │ ├── filetype │ │ └── build.go │ ├── flags │ │ ├── flags.go │ │ ├── proto_legacy_disable.go │ │ └── proto_legacy_enable.go │ ├── genid │ │ ├── any_gen.go │ │ ├── api_gen.go │ │ ├── descriptor_gen.go │ │ ├── doc.go │ │ ├── duration_gen.go │ │ ├── empty_gen.go │ │ ├── field_mask_gen.go │ │ ├── goname.go │ │ ├── map_entry.go │ │ ├── source_context_gen.go │ │ ├── struct_gen.go │ │ ├── timestamp_gen.go │ │ ├── type_gen.go │ │ ├── wrappers.go │ │ └── wrappers_gen.go │ ├── impl │ │ ├── api_export.go │ │ ├── checkinit.go │ │ ├── codec_extension.go │ │ ├── codec_field.go │ │ ├── codec_gen.go │ │ ├── codec_map.go │ │ ├── codec_map_go111.go │ │ ├── codec_map_go112.go │ │ ├── codec_message.go │ │ ├── codec_messageset.go │ │ ├── codec_reflect.go │ │ ├── codec_tables.go │ │ ├── codec_unsafe.go │ │ ├── convert.go │ │ ├── convert_list.go │ │ ├── convert_map.go │ │ ├── decode.go │ │ ├── encode.go │ │ ├── enum.go │ │ ├── extension.go │ │ ├── legacy_enum.go │ │ ├── legacy_export.go │ │ ├── legacy_extension.go │ │ ├── legacy_file.go │ │ ├── legacy_message.go │ │ ├── merge.go │ │ ├── merge_gen.go │ │ ├── message.go │ │ ├── message_reflect.go │ │ ├── message_reflect_field.go │ │ ├── message_reflect_gen.go │ │ ├── pointer_reflect.go │ │ ├── pointer_unsafe.go │ │ ├── validate.go │ │ └── weak.go │ ├── order │ │ ├── order.go │ │ └── range.go │ ├── pragma │ │ └── pragma.go │ ├── set │ │ └── ints.go │ ├── strs │ │ ├── strings.go │ │ ├── strings_pure.go │ │ └── strings_unsafe.go │ └── version │ │ └── version.go │ ├── proto │ ├── checkinit.go │ ├── decode.go │ ├── decode_gen.go │ ├── doc.go │ ├── encode.go │ ├── encode_gen.go │ ├── equal.go │ ├── extension.go │ ├── merge.go │ ├── messageset.go │ ├── proto.go │ ├── proto_methods.go │ ├── proto_reflect.go │ ├── reset.go │ ├── size.go │ ├── size_gen.go │ └── wrappers.go │ ├── reflect │ ├── protodesc │ │ ├── desc.go │ │ ├── desc_init.go │ │ ├── desc_resolve.go │ │ ├── desc_validate.go │ │ └── proto.go │ ├── protoreflect │ │ ├── methods.go │ │ ├── proto.go │ │ ├── source.go │ │ ├── source_gen.go │ │ ├── type.go │ │ ├── value.go │ │ ├── value_pure.go │ │ ├── value_union.go │ │ └── value_unsafe.go │ └── protoregistry │ │ └── registry.go │ ├── runtime │ ├── protoiface │ │ ├── legacy.go │ │ └── methods.go │ └── protoimpl │ │ ├── impl.go │ │ └── version.go │ └── types │ └── descriptorpb │ └── descriptor.pb.go ├── gopkg.in ├── tomb.v1 │ ├── LICENSE │ ├── README.md │ └── tomb.go ├── validator.v2 │ ├── .gitignore │ ├── .travis.yml │ ├── LICENSE │ ├── README.md │ ├── builtins.go │ ├── doc.go │ └── validator.go └── yaml.v2 │ ├── .travis.yml │ ├── LICENSE │ ├── LICENSE.libyaml │ ├── NOTICE │ ├── README.md │ ├── apic.go │ ├── decode.go │ ├── emitterc.go │ ├── encode.go │ ├── go.mod │ ├── parserc.go │ ├── readerc.go │ ├── resolve.go │ ├── scannerc.go │ ├── sorter.go │ ├── writerc.go │ ├── yaml.go │ ├── yamlh.go │ └── yamlprivateh.go └── modules.txt /.gitignore: -------------------------------------------------------------------------------- 1 | .idea 2 | .DS_Store 3 | *.test 4 | *.swp 5 | *~ 6 | *# 7 | #* 8 | node_modules 9 | tmp 10 | out 11 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - 1.4.2 5 | 6 | install: 7 | - go get -t -v ./... 8 | - go install github.com/onsi/ginkgo/ginkgo 9 | - wget https://s3.amazonaws.com/travis-phantomjs/phantomjs-2.0.0-ubuntu-12.04.tar.bz2 10 | - tar xjf phantomjs-2.0.0-ubuntu-12.04.tar.bz2 11 | - sudo rm -rf /usr/local/phantomjs/bin/phantomjs 12 | - sudo mv phantomjs /usr/local/phantomjs/bin/phantomjs 13 | 14 | before_script: 15 | - export PATH=$HOME/gopath/bin:$PATH 16 | 17 | script: 18 | - ./bin/test -nodes=2 # travis would occasionally kill tests running on too many threads 19 | - ./bin/test-ui 20 | -------------------------------------------------------------------------------- /NOTICE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2015-Present CloudFoundry.org Foundation, Inc. All Rights Reserved. 2 | 3 | This project contains software that is Copyright (c) 2012-2015 Pivotal Software, Inc. 4 | 5 | This project is licensed to you under the Apache License, Version 2.0 (the "License"). 6 | 7 | You may not use this project except in compliance with the License. 8 | 9 | This project may include a number of subcomponents with separate copyright notices 10 | and license terms. Your use of these subcomponents is subject to the terms and 11 | conditions of the subcomponent's license, as noted in the LICENSE file. 12 | -------------------------------------------------------------------------------- /Procfile: -------------------------------------------------------------------------------- 1 | web: gulp s 2 | jasmine: gulp jasmine -------------------------------------------------------------------------------- /api/api_suite_test.go: -------------------------------------------------------------------------------- 1 | package api_test 2 | 3 | import ( 4 | "testing" 5 | 6 | . "github.com/onsi/ginkgo" 7 | . "github.com/onsi/gomega" 8 | ) 9 | 10 | func TestSwitchboardAPI(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Switchboard API Suite") 13 | } 14 | -------------------------------------------------------------------------------- /api/handler.go: -------------------------------------------------------------------------------- 1 | package api 2 | 3 | import ( 4 | "net/http" 5 | 6 | "code.cloudfoundry.org/lager" 7 | "github.com/cloudfoundry-incubator/switchboard/api/middleware" 8 | "github.com/cloudfoundry-incubator/switchboard/config" 9 | "github.com/cloudfoundry-incubator/switchboard/domain" 10 | ) 11 | 12 | func NewHandler( 13 | clusterManager ClusterManager, 14 | backends []*domain.Backend, 15 | logger lager.Logger, 16 | apiConfig config.API, 17 | staticDir string, 18 | ) http.Handler { 19 | mux := http.NewServeMux() 20 | 21 | mux.Handle("/", http.FileServer(http.Dir(staticDir))) 22 | 23 | mux.Handle("/v0/backends", BackendsIndex(backends, clusterManager)) 24 | mux.Handle("/v0/cluster", ClusterEndpoint(clusterManager, logger)) 25 | 26 | return middleware.Chain{ 27 | middleware.NewPanicRecovery(logger), 28 | middleware.NewLogger(logger, "/v0"), 29 | middleware.NewHttpsEnforcer(apiConfig.ForceHttps), 30 | middleware.NewBasicAuth(apiConfig.Username, apiConfig.Password), 31 | }.Wrap(mux) 32 | } 33 | -------------------------------------------------------------------------------- /api/middleware/basic_auth.go: -------------------------------------------------------------------------------- 1 | package middleware 2 | 3 | import ( 4 | "crypto/subtle" 5 | "net/http" 6 | ) 7 | 8 | type BasicAuth struct { 9 | Username, Password string 10 | } 11 | 12 | func NewBasicAuth(username, password string) Middleware { 13 | return BasicAuth{ 14 | Username: username, 15 | Password: password, 16 | } 17 | } 18 | 19 | func (b BasicAuth) Wrap(next http.Handler) http.Handler { 20 | return http.HandlerFunc(func(rw http.ResponseWriter, req *http.Request) { 21 | username, password, ok := req.BasicAuth() 22 | if ok && 23 | secureCompare(username, b.Username) && 24 | secureCompare(password, b.Password) { 25 | next.ServeHTTP(rw, req) 26 | } else { 27 | rw.Header().Set("WWW-Authenticate", "Basic realm=\"Authorization Required\"") 28 | http.Error(rw, "Not Authorized", http.StatusUnauthorized) 29 | } 30 | }) 31 | } 32 | 33 | func secureCompare(a, b string) bool { 34 | x := []byte(a) 35 | y := []byte(b) 36 | return subtle.ConstantTimeCompare(x, y) == 1 37 | } 38 | -------------------------------------------------------------------------------- /api/middleware/chain.go: -------------------------------------------------------------------------------- 1 | package middleware 2 | 3 | import "net/http" 4 | 5 | type Chain []Middleware 6 | 7 | func (mc Chain) Wrap(next http.Handler) http.Handler { 8 | var chain http.Handler = next 9 | 10 | middlewareCount := len(mc) 11 | for i := middlewareCount - 1; i >= 0; i-- { // iterate backwards 12 | chain = mc[i].Wrap(chain) 13 | } 14 | return chain 15 | } 16 | -------------------------------------------------------------------------------- /api/middleware/middleware.go: -------------------------------------------------------------------------------- 1 | package middleware 2 | 3 | import "net/http" 4 | 5 | type Middleware interface { 6 | Wrap(http.Handler) http.Handler 7 | } 8 | -------------------------------------------------------------------------------- /api/middleware/middleware_suite_test.go: -------------------------------------------------------------------------------- 1 | package middleware_test 2 | 3 | import ( 4 | "testing" 5 | 6 | . "github.com/onsi/ginkgo" 7 | . "github.com/onsi/gomega" 8 | ) 9 | 10 | func TestMiddleware(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Middleware Suite") 13 | } 14 | -------------------------------------------------------------------------------- /api/middleware/panic_recovery.go: -------------------------------------------------------------------------------- 1 | package middleware 2 | 3 | import ( 4 | "net/http" 5 | 6 | "code.cloudfoundry.org/lager" 7 | ) 8 | 9 | type PanicRecovery struct { 10 | logger lager.Logger 11 | } 12 | 13 | func NewPanicRecovery(logger lager.Logger) Middleware { 14 | return &PanicRecovery{logger} 15 | } 16 | 17 | func (p PanicRecovery) Wrap(next http.Handler) http.Handler { 18 | return http.HandlerFunc(func(rw http.ResponseWriter, req *http.Request) { 19 | defer func() { 20 | if panicInfo := recover(); panicInfo != nil { 21 | rw.WriteHeader(http.StatusInternalServerError) 22 | p.logger.Error("Panic while serving request", nil, lager.Data{ 23 | "panicInfo": panicInfo, 24 | }) 25 | } 26 | }() 27 | next.ServeHTTP(rw, req) 28 | }) 29 | } 30 | -------------------------------------------------------------------------------- /apiaggregator/apiaggregator_suite_test.go: -------------------------------------------------------------------------------- 1 | package apiaggregator_test 2 | 3 | import ( 4 | "testing" 5 | 6 | . "github.com/onsi/ginkgo" 7 | . "github.com/onsi/gomega" 8 | ) 9 | 10 | func TestSwitchboardAPIAggregator(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Switchboard API Aggregator Suite") 13 | } 14 | -------------------------------------------------------------------------------- /app/images/switchboard-header-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/app/images/switchboard-header-logo.png -------------------------------------------------------------------------------- /app/stylesheets/_switchboard.styl: -------------------------------------------------------------------------------- 1 | p, ol, ul, td { 2 | font-family: verdana, arial, helvetica, sans-serif; 3 | font-size: 13px; 4 | line-height: 18px; 5 | } 6 | 7 | pre { 8 | background-color: #eee; 9 | padding: 10px; 10 | font-size: 11px; 11 | } 12 | 13 | a { 14 | color: #000; 15 | } 16 | 17 | a:visited { 18 | color: #666; 19 | } 20 | 21 | div.field, div.actions { 22 | margin-bottom: 10px; 23 | } 24 | 25 | #notice { 26 | color: green; 27 | } 28 | 29 | .field_with_errors { 30 | padding: 2px; 31 | background-color: red; 32 | display: table; 33 | } 34 | 35 | #error_explanation { 36 | width: 450px; 37 | border: 2px solid red; 38 | padding: 7px; 39 | padding-bottom: 0; 40 | margin-bottom: 20px; 41 | background-color: #f0f0f0; 42 | } 43 | 44 | #error_explanation h2 { 45 | text-align: left; 46 | font-weight: bold; 47 | padding: 5px 5px 5px 15px; 48 | font-size: 12px; 49 | margin: -7px; 50 | margin-bottom: 0px; 51 | background-color: #c00; 52 | color: #fff; 53 | } 54 | #error_explanation ul li { 55 | font-size: 12px; 56 | list-style: square; 57 | } -------------------------------------------------------------------------------- /app/stylesheets/application.styl: -------------------------------------------------------------------------------- 1 | @require '_switchboard'; 2 | -------------------------------------------------------------------------------- /bin/build: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | root_dir=$(cd $(dirname $(dirname "$0")) && pwd) 6 | 7 | go build -o "${root_dir}/out/switchboard" "github.com/cloudfoundry-incubator/switchboard" 8 | -------------------------------------------------------------------------------- /bin/build-ui: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -eux 4 | 5 | MY_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 6 | 7 | # This script expects to live one directory below the base directory. 8 | BASE_DIR=$( cd $MY_DIR/.. && pwd ) 9 | 10 | pushd $BASE_DIR 11 | npm install 12 | npm install -g gulp 13 | gulp assets 14 | popd 15 | -------------------------------------------------------------------------------- /bin/govet: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | SRC_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )" 6 | 7 | go vet -composites=false $SRC_DIR/... 8 | -------------------------------------------------------------------------------- /bin/regenerate-fakes: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | goversion=1.7 4 | 5 | GOPATH="/usr/local/Cellar/go/${goversion}/libexec/:${GOPATH}" go generate $(go list ./... | grep -v /vendor/) 6 | -------------------------------------------------------------------------------- /bin/serve-ui: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -eux 4 | 5 | MY_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 6 | 7 | # This script expects to live one directory below the base directory. 8 | BASE_DIR=$( cd $MY_DIR/.. && pwd ) 9 | 10 | pushd $BASE_DIR 11 | npm install 12 | npm install -g gulp 13 | gulp s 14 | popd 15 | -------------------------------------------------------------------------------- /bin/test: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | result=0 4 | 5 | my_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 6 | OS="$(uname)" 7 | 8 | function get_cpu_count() { 9 | if [[ "${OS}" == "Darwin" ]]; then 10 | sysctl -n hw.ncpu 11 | else 12 | nproc 13 | fi 14 | } 15 | 16 | cd "${my_dir}/.." || exit 1 17 | 18 | echo -e "\nVetting packages for potential issues..." 19 | "${my_dir}/govet" 20 | 21 | echo -e "\nTesting packages..." 22 | 23 | # due to the high amount of concurrency in these tests, tests will often fail 24 | # with timeouts if run in parallel on systems with fewer than 4 cores 25 | GINKGO_FLAGS="-r -failOnPending -randomizeAllSpecs -slowSpecThreshold=20 -race -keepGoing" 26 | if [[ "$(get_cpu_count)" -ge "4" && "${OS}" == "Darwin" ]]; then 27 | GINKGO_FLAGS="${GINKGO_FLAGS} -p" 28 | fi 29 | 30 | # shellcheck disable=SC2086 31 | go run github.com/onsi/ginkgo/ginkgo ${GINKGO_FLAGS} "$@" 32 | let "result+=$?" 33 | 34 | echo -e "\nExit Code: $result" 35 | exit $result 36 | -------------------------------------------------------------------------------- /bin/test-n-times: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | result=0 4 | 5 | MY_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 6 | 7 | RUN_COUNT="$1" 8 | if [[ -z "$RUN_COUNT" ]] 9 | then 10 | echo -e "\nRun Count not specified, exiting..." 11 | exit 1 12 | fi 13 | shift 14 | echo -e "\nRunning tests $RUN_COUNT times" 15 | 16 | echo -e "\nTesting packages..." 17 | 18 | for ((i = 1; i <= $RUN_COUNT; i++)) 19 | do 20 | echo -e "\nTest Run: $i" 21 | ginkgo -p -r -race -failOnPending -randomizeAllSpecs "$@" $MY_DIR/.. 22 | TEST_RESULT="$?" 23 | if [[ $TEST_RESULT -ne 0 ]]; then 24 | echo -e "\nGinkgo Exit Code: $TEST_RESULT" 25 | exit $TEST_RESULT 26 | fi 27 | done 28 | -------------------------------------------------------------------------------- /bin/test-ui: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -eux 4 | 5 | MY_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 6 | 7 | # This script expects to live one directory below the base directory. 8 | BASE_DIR=$( cd $MY_DIR/.. && pwd ) 9 | 10 | pushd $BASE_DIR 11 | npm install 12 | npm install -g gulp 13 | gulp 14 | popd 15 | -------------------------------------------------------------------------------- /config/config_suite_test.go: -------------------------------------------------------------------------------- 1 | package config_test 2 | 3 | import ( 4 | . "github.com/onsi/ginkgo" 5 | . "github.com/onsi/gomega" 6 | 7 | "testing" 8 | ) 9 | 10 | func TestSwitchboarConfig(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Switchboard Config Suite") 13 | } 14 | -------------------------------------------------------------------------------- /config/fixtures/emptyAPI.yml: -------------------------------------------------------------------------------- 1 | Proxy: 2 | Port: 0 3 | HealthcheckTimeoutMillis: 0 4 | Backends: 5 | ProfilerPort: 0 6 | HealthPort: 0 7 | -------------------------------------------------------------------------------- /config/fixtures/emptyHealthPort.yml: -------------------------------------------------------------------------------- 1 | Proxy: 2 | Port: 0 3 | HealthcheckTimeoutMillis: 0 4 | Backends: 5 | API: 6 | Port: 0 7 | Username: "" 8 | Password: "" 9 | ProfilerPort: 0 10 | -------------------------------------------------------------------------------- /config/fixtures/emptyProxy.yml: -------------------------------------------------------------------------------- 1 | API: 2 | Port: 0 3 | Username: "" 4 | Password: "" 5 | ProfilerPort: 0 6 | HealthPort: 0 7 | -------------------------------------------------------------------------------- /config/fixtures/invalidFields.yml: -------------------------------------------------------------------------------- 1 | Proxy: 2 | Port: 0 3 | HealthcheckTimeoutMillis: 0 4 | Backends: 5 | - Host: "" 6 | Port: 0 7 | HealthcheckPort: 0 8 | Name: "" 9 | API: 10 | Port: 0 11 | Username: "" 12 | Password: "" 13 | ProfilerPort: 0 14 | HealthPort: 0 15 | -------------------------------------------------------------------------------- /config/fixtures/validConfig.yml: -------------------------------------------------------------------------------- 1 | API: 2 | Port: 80 3 | AggregatorPort: 8081 4 | Username: fake-username 5 | Password: fake-password 6 | ForceHttps: true 7 | Proxy: 8 | Port: 3306 9 | HealthcheckTimeoutMillis: 5000 10 | Backends: 11 | - Host: 10.10.10.10 12 | Port: 3306 13 | StatusPort: 9200 14 | StatusEndpoint: galera_healthcheck 15 | Name: backend-0 16 | HealthPort: 9200 17 | StaticDir: fake-path 18 | -------------------------------------------------------------------------------- /domain/backends.go: -------------------------------------------------------------------------------- 1 | package domain 2 | 3 | import ( 4 | "code.cloudfoundry.org/lager" 5 | "github.com/cloudfoundry-incubator/switchboard/config" 6 | ) 7 | 8 | var BackendProvider = NewBackend 9 | 10 | func NewBackends(backendConfigs []config.Backend, logger lager.Logger) (backends []*Backend) { 11 | for _, bc := range backendConfigs { 12 | backends = append(backends, BackendProvider( 13 | bc.Name, 14 | bc.Host, 15 | bc.Port, 16 | bc.StatusPort, 17 | bc.StatusEndpoint, 18 | logger, 19 | )) 20 | } 21 | 22 | return backends 23 | } 24 | -------------------------------------------------------------------------------- /domain/domain_suite_test.go: -------------------------------------------------------------------------------- 1 | package domain_test 2 | 3 | import ( 4 | "testing" 5 | "time" 6 | 7 | . "github.com/onsi/ginkgo" 8 | . "github.com/onsi/gomega" 9 | ) 10 | 11 | func TestSwitchboardDomain(t *testing.T) { 12 | 13 | // this suite involves a high amount of concurrency 14 | // setting the timeout higher reduces flakiness on systems 15 | // with fewer cores 16 | SetDefaultEventuallyTimeout(5 * time.Second) 17 | SetDefaultEventuallyPollingInterval(500 * time.Millisecond) 18 | 19 | RegisterFailHandler(Fail) 20 | RunSpecs(t, "Switchboard Domain Suite") 21 | } 22 | -------------------------------------------------------------------------------- /domain/messages.go: -------------------------------------------------------------------------------- 1 | package domain 2 | 3 | func BroadcastBool(in <-chan bool, outs []chan<- bool) { 4 | go func() { 5 | for i := range in { 6 | for _, out := range outs { 7 | out <- i 8 | } 9 | } 10 | }() 11 | } 12 | -------------------------------------------------------------------------------- /go.mod: -------------------------------------------------------------------------------- 1 | module github.com/cloudfoundry-incubator/switchboard 2 | 3 | go 1.14 4 | 5 | require ( 6 | code.cloudfoundry.org/lager v2.0.0+incompatible 7 | github.com/cloudfoundry-incubator/galera-healthcheck v0.0.0-20210824173504-1ceac3424420 8 | github.com/fsnotify/fsnotify v1.5.1 // indirect 9 | github.com/maxbrunsfeld/counterfeiter/v6 v6.2.3 10 | github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d // indirect 11 | github.com/onsi/ginkgo v1.16.4 12 | github.com/onsi/gomega v1.16.0 13 | github.com/pivotal-cf-experimental/service-config v0.0.0-20160129003516-b1dc94de6ada 14 | github.com/tedsuo/ifrit v0.0.0-20191009134036-9a97d0632f00 15 | gopkg.in/validator.v2 v2.0.0-20210331031555-b37d688a7fb0 16 | ) 17 | -------------------------------------------------------------------------------- /gulpfile.js: -------------------------------------------------------------------------------- 1 | require('babel/register')({experimental: true}); 2 | require('./gulptasks'); -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | require('babel/register')({experimental: true}); 2 | require('./serve/serve'); -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-black-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-black-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-black-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-black-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-black-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-black-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-bold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-bold-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-bold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-bold-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-bold-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-extralight-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-extralight-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-extralight-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-extralight-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-extralight-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-extralight-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-it-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-it-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-it-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-it-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-it-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-it-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-light-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-light-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-light-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-light-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-light-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-regular-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-regular-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-regular-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-regular-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-regular-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-semibold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-semibold-webfont.eot -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-semibold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-semibold-webfont.ttf -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/fonts/sourcesanspro-semibold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/fonts/sourcesanspro-semibold-webfont.woff -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/aboutus-hero.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/aboutus-hero.jpg -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/console-laptop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/console-laptop.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/favicon.ico -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/gray-cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/gray-cloud.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/img--examplesDebra.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/img--examplesDebra.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/img--examplesGary.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/img--examplesGary.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/img--examplesKelly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/img--examplesKelly.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/img--examplesTodd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/img--examplesTodd.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/logo-pcf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/logo-pcf.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/logo-pws.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/logo-pws.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/logo.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/open-source-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/open-source-icon.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/p-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/p-logo.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/pivotal_footer_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/pivotal_footer_logo.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/pivotal_footer_logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/pivotal_footer_logo@2x.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/pui-logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/pui-logo@2x.png -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/such-awesome.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/such-awesome.jpg -------------------------------------------------------------------------------- /js-vendor/pui-v1.4.0/images/we-care-sprites.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/js-vendor/pui-v1.4.0/images/we-care-sprites.png -------------------------------------------------------------------------------- /main_suite_test.go: -------------------------------------------------------------------------------- 1 | package main_test 2 | 3 | import ( 4 | "path" 5 | "runtime" 6 | "testing" 7 | 8 | . "github.com/onsi/ginkgo" 9 | . "github.com/onsi/gomega" 10 | "github.com/onsi/gomega/gexec" 11 | ) 12 | 13 | const ( 14 | switchboardPackage = "github.com/cloudfoundry-incubator/switchboard/" 15 | ) 16 | 17 | func TestSwitchboard(t *testing.T) { 18 | RegisterFailHandler(Fail) 19 | RunSpecs(t, "Switchboard Executable Suite") 20 | } 21 | 22 | var ( 23 | switchboardBinPath string 24 | ) 25 | 26 | var _ = BeforeSuite(func() { 27 | var err error 28 | switchboardBinPath, err = gexec.Build(switchboardPackage, "-race") 29 | Expect(err).NotTo(HaveOccurred()) 30 | }) 31 | 32 | func getDirOfCurrentFile() string { 33 | _, filename, _, _ := runtime.Caller(1) 34 | return path.Dir(filename) 35 | } 36 | 37 | var _ = AfterSuite(func() { 38 | gexec.CleanupBuildArtifacts() 39 | }) 40 | -------------------------------------------------------------------------------- /runner/api/api_suite_test.go: -------------------------------------------------------------------------------- 1 | package api_test 2 | 3 | import ( 4 | . "github.com/onsi/ginkgo" 5 | . "github.com/onsi/gomega" 6 | 7 | "testing" 8 | ) 9 | 10 | func TestApi(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Api Runner Suite") 13 | } 14 | -------------------------------------------------------------------------------- /runner/api/runner.go: -------------------------------------------------------------------------------- 1 | package api 2 | 3 | import ( 4 | "fmt" 5 | "net/http" 6 | 7 | "github.com/tedsuo/ifrit" 8 | "github.com/tedsuo/ifrit/http_server" 9 | ) 10 | 11 | func NewRunner(port uint, handler http.Handler) ifrit.Runner { 12 | return http_server.New(fmt.Sprintf("0.0.0.0:%d", port), handler) 13 | } 14 | -------------------------------------------------------------------------------- /runner/api/runner_test.go: -------------------------------------------------------------------------------- 1 | package api_test 2 | 3 | import ( 4 | "fmt" 5 | "net" 6 | "os" 7 | 8 | "github.com/cloudfoundry-incubator/switchboard/runner/api" 9 | 10 | . "github.com/onsi/ginkgo" 11 | . "github.com/onsi/gomega" 12 | "github.com/tedsuo/ifrit" 13 | ) 14 | 15 | var _ = Describe("APIRunner", func() { 16 | It("shuts down gracefully when signalled", func() { 17 | apiPort := 10000 + GinkgoParallelNode() 18 | apiRunner := api.NewRunner(uint(apiPort), nil) 19 | apiProcess := ifrit.Invoke(apiRunner) 20 | apiProcess.Signal(os.Kill) 21 | Eventually(apiProcess.Wait()).Should(Receive()) 22 | 23 | _, err := net.Dial("tcp", fmt.Sprintf("127.0.0.1:%d", apiPort)) 24 | Expect(err).To(HaveOccurred()) 25 | }) 26 | }) 27 | -------------------------------------------------------------------------------- /runner/apiaggregator/api_suite_test.go: -------------------------------------------------------------------------------- 1 | package apiaggregator_test 2 | 3 | import ( 4 | . "github.com/onsi/ginkgo" 5 | . "github.com/onsi/gomega" 6 | 7 | "testing" 8 | ) 9 | 10 | func TestApi(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "API Aggregator Runner Suite") 13 | } 14 | -------------------------------------------------------------------------------- /runner/apiaggregator/runner.go: -------------------------------------------------------------------------------- 1 | package apiaggregator 2 | 3 | import ( 4 | "fmt" 5 | "net/http" 6 | 7 | "github.com/tedsuo/ifrit" 8 | "github.com/tedsuo/ifrit/http_server" 9 | ) 10 | 11 | func NewRunner(port uint, handler http.Handler) ifrit.Runner { 12 | return http_server.New(fmt.Sprintf("0.0.0.0:%d", port), handler) 13 | } 14 | -------------------------------------------------------------------------------- /runner/apiaggregator/runner_test.go: -------------------------------------------------------------------------------- 1 | package apiaggregator_test 2 | 3 | import ( 4 | "fmt" 5 | "net" 6 | "os" 7 | 8 | "github.com/cloudfoundry-incubator/switchboard/runner/apiaggregator" 9 | . "github.com/onsi/ginkgo" 10 | . "github.com/onsi/gomega" 11 | "github.com/tedsuo/ifrit" 12 | ) 13 | 14 | var _ = Describe("APIRunner", func() { 15 | It("shuts down gracefully when signalled", func() { 16 | apiPort := 20000 + GinkgoParallelNode() 17 | apiRunner := apiaggregator.NewRunner(uint(apiPort), nil) 18 | apiProcess := ifrit.Invoke(apiRunner) 19 | apiProcess.Signal(os.Kill) 20 | Eventually(apiProcess.Wait()).Should(Receive()) 21 | 22 | _, err := net.Dial("tcp", fmt.Sprintf("127.0.0.1:%d", apiPort)) 23 | Expect(err).To(HaveOccurred()) 24 | }) 25 | }) 26 | -------------------------------------------------------------------------------- /runner/bridge/bridge_suite_test.go: -------------------------------------------------------------------------------- 1 | package bridge_test 2 | 3 | import ( 4 | . "github.com/onsi/ginkgo" 5 | . "github.com/onsi/gomega" 6 | 7 | "testing" 8 | ) 9 | 10 | func TestBridge(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Bridge Runner Suite") 13 | } 14 | -------------------------------------------------------------------------------- /runner/health/health_suite_test.go: -------------------------------------------------------------------------------- 1 | package health_test 2 | 3 | import ( 4 | "testing" 5 | 6 | . "github.com/onsi/ginkgo" 7 | . "github.com/onsi/gomega" 8 | ) 9 | 10 | func TestSwitchboardHealth(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Switchboard Health Suite") 13 | } 14 | -------------------------------------------------------------------------------- /runner/health/runner.go: -------------------------------------------------------------------------------- 1 | package health 2 | 3 | import ( 4 | "fmt" 5 | 6 | "net/http" 7 | 8 | "github.com/tedsuo/ifrit" 9 | "github.com/tedsuo/ifrit/http_server" 10 | ) 11 | 12 | func NewRunner(port uint) ifrit.Runner { 13 | return http_server.New(fmt.Sprintf("0.0.0.0:%d", port), http.HandlerFunc(func(rw http.ResponseWriter, req *http.Request) { 14 | rw.WriteHeader(200) 15 | })) 16 | } 17 | -------------------------------------------------------------------------------- /runner/monitor/decision_counters.go: -------------------------------------------------------------------------------- 1 | package monitor 2 | 3 | type DecisionCounters struct { 4 | counters map[string]uint64 5 | conditionals map[string]func() bool 6 | } 7 | 8 | func NewDecisionCounters() *DecisionCounters { 9 | return &DecisionCounters{ 10 | counters: map[string]uint64{}, 11 | conditionals: map[string]func() bool{}, 12 | } 13 | } 14 | 15 | func (c *DecisionCounters) GetCount(name string) uint64 { 16 | return c.counters[name] 17 | } 18 | 19 | func (c *DecisionCounters) IncrementCount(name string) { 20 | c.counters[name] += 1 21 | } 22 | 23 | func (c *DecisionCounters) ResetCount(name string) { 24 | c.counters[name] = 0 25 | } 26 | 27 | func (c *DecisionCounters) AddCondition(taskName string, predicate func() bool) { 28 | c.conditionals[taskName] = predicate 29 | } 30 | 31 | func (c *DecisionCounters) Should(taskName string) bool { 32 | f, ok := c.conditionals[taskName] 33 | 34 | if !ok { 35 | return false 36 | } 37 | 38 | return f() 39 | } 40 | -------------------------------------------------------------------------------- /runner/monitor/monitor_suite_test.go: -------------------------------------------------------------------------------- 1 | package monitor_test 2 | 3 | import ( 4 | . "github.com/onsi/ginkgo" 5 | . "github.com/onsi/gomega" 6 | 7 | "testing" 8 | ) 9 | 10 | func TestMonitor(t *testing.T) { 11 | RegisterFailHandler(Fail) 12 | RunSpecs(t, "Monitor Runner Suite") 13 | } 14 | -------------------------------------------------------------------------------- /runner/monitor/runner.go: -------------------------------------------------------------------------------- 1 | package monitor 2 | 3 | import ( 4 | "os" 5 | 6 | "code.cloudfoundry.org/lager" 7 | ) 8 | 9 | //go:generate go run github.com/maxbrunsfeld/counterfeiter/v6 . Monitor 10 | type Monitor interface { 11 | Monitor(<-chan interface{}) 12 | } 13 | 14 | type Runner struct { 15 | logger lager.Logger 16 | monitor Monitor 17 | } 18 | 19 | func NewRunner(monitor Monitor, logger lager.Logger) Runner { 20 | return Runner{ 21 | logger: logger, 22 | monitor: monitor, 23 | } 24 | } 25 | 26 | func (pr Runner) Run(signals <-chan os.Signal, ready chan<- struct{}) error { 27 | shutdown := make(chan interface{}) 28 | pr.monitor.Monitor(shutdown) 29 | 30 | close(ready) 31 | 32 | signal := <-signals 33 | pr.logger.Info("Received signal", lager.Data{"signal": signal}) 34 | close(shutdown) 35 | 36 | return nil 37 | } 38 | -------------------------------------------------------------------------------- /runner/monitor/runner_test.go: -------------------------------------------------------------------------------- 1 | package monitor_test 2 | 3 | import ( 4 | "os" 5 | 6 | "code.cloudfoundry.org/lager/lagertest" 7 | "github.com/cloudfoundry-incubator/switchboard/runner/monitor" 8 | "github.com/cloudfoundry-incubator/switchboard/runner/monitor/monitorfakes" 9 | . "github.com/onsi/ginkgo" 10 | . "github.com/onsi/gomega" 11 | "github.com/tedsuo/ifrit" 12 | ) 13 | 14 | var _ = Describe("Monitor Runner", func() { 15 | It("shuts down gracefully when signalled", func() { 16 | m := new(monitorfakes.FakeMonitor) 17 | 18 | logger := lagertest.NewTestLogger("Monitor Runner test") 19 | monitorRunner := monitor.NewRunner(m, logger) 20 | monitorProcess := ifrit.Invoke(monitorRunner) 21 | 22 | shutdownChan := m.MonitorArgsForCall(0) 23 | Consistently(shutdownChan).ShouldNot(BeClosed()) 24 | 25 | monitorProcess.Signal(os.Kill) 26 | Eventually(monitorProcess.Wait()).Should(Receive()) 27 | 28 | Expect(shutdownChan).To(BeClosed()) 29 | }) 30 | }) 31 | -------------------------------------------------------------------------------- /serve/serve.js: -------------------------------------------------------------------------------- 1 | var React = require('react/addons'); 2 | var Layout = require('./components/layout'); 3 | 4 | module.exports = function() { 5 | var Application = require('../app/components/application'); 6 | var stylesheets = ['pivotal-ui.min.css', 'application.css']; 7 | var scripts = ['application.js']; 8 | var config = {}; 9 | var className = 'bg-neutral-9'; 10 | var props = {entry: Application, stylesheets, scripts, config, className}; 11 | return React.renderToStaticMarkup(); 12 | }; -------------------------------------------------------------------------------- /spec/app/spec_helper.js: -------------------------------------------------------------------------------- 1 | global.React = require('react/addons'); 2 | var jQuery = require('jquery'); 3 | global.jQuery = jQuery; 4 | global.$ = jQuery; 5 | 6 | require('jasmine-ajax'); 7 | require('jasmine_dom_matchers'); 8 | 9 | beforeEach(function() { 10 | var Layout = require('../../serve/components/layout'); 11 | spyOn(Layout, 'init'); 12 | 13 | jasmine.clock().install(); 14 | jasmine.Ajax.install(); 15 | 16 | $('body').find('#root').remove().end().append('
'); 17 | }); 18 | 19 | afterEach(function() { 20 | jasmine.Ajax.uninstall(); 21 | jasmine.clock().uninstall(); 22 | }); 23 | -------------------------------------------------------------------------------- /static/_switchboard.css: -------------------------------------------------------------------------------- 1 | p, 2 | ol, 3 | ul, 4 | td { 5 | font-family: verdana, arial, helvetica, sans-serif; 6 | font-size: 13px; 7 | line-height: 18px; 8 | } 9 | pre { 10 | background-color: #eee; 11 | padding: 10px; 12 | font-size: 11px; 13 | } 14 | a { 15 | color: #000; 16 | } 17 | a:visited { 18 | color: #666; 19 | } 20 | div.field, 21 | div.actions { 22 | margin-bottom: 10px; 23 | } 24 | #notice { 25 | color: #008000; 26 | } 27 | .field_with_errors { 28 | padding: 2px; 29 | background-color: #f00; 30 | display: table; 31 | } 32 | #error_explanation { 33 | width: 450px; 34 | border: 2px solid #f00; 35 | padding: 7px; 36 | padding-bottom: 0; 37 | margin-bottom: 20px; 38 | background-color: #f0f0f0; 39 | } 40 | #error_explanation h2 { 41 | text-align: left; 42 | font-weight: bold; 43 | padding: 5px 5px 5px 15px; 44 | font-size: 12px; 45 | margin: -7px; 46 | margin-bottom: 0px; 47 | background-color: #c00; 48 | color: #fff; 49 | } 50 | #error_explanation ul li { 51 | font-size: 12px; 52 | list-style: square; 53 | } 54 | -------------------------------------------------------------------------------- /static/application.css: -------------------------------------------------------------------------------- 1 | p, 2 | ol, 3 | ul, 4 | td { 5 | font-family: verdana, arial, helvetica, sans-serif; 6 | font-size: 13px; 7 | line-height: 18px; 8 | } 9 | pre { 10 | background-color: #eee; 11 | padding: 10px; 12 | font-size: 11px; 13 | } 14 | a { 15 | color: #000; 16 | } 17 | a:visited { 18 | color: #666; 19 | } 20 | div.field, 21 | div.actions { 22 | margin-bottom: 10px; 23 | } 24 | #notice { 25 | color: #008000; 26 | } 27 | .field_with_errors { 28 | padding: 2px; 29 | background-color: #f00; 30 | display: table; 31 | } 32 | #error_explanation { 33 | width: 450px; 34 | border: 2px solid #f00; 35 | padding: 7px; 36 | padding-bottom: 0; 37 | margin-bottom: 20px; 38 | background-color: #f0f0f0; 39 | } 40 | #error_explanation h2 { 41 | text-align: left; 42 | font-weight: bold; 43 | padding: 5px 5px 5px 15px; 44 | font-size: 12px; 45 | margin: -7px; 46 | margin-bottom: 0px; 47 | background-color: #c00; 48 | color: #fff; 49 | } 50 | #error_explanation ul li { 51 | font-size: 12px; 52 | list-style: square; 53 | } 54 | -------------------------------------------------------------------------------- /static/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-black-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-black-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-black-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-black-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-black-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-black-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-bold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-bold-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-bold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-bold-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-bold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-bold-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-extralight-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-extralight-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-extralight-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-extralight-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-extralight-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-extralight-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-it-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-it-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-it-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-it-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-it-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-it-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-light-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-light-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-light-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-light-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-light-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-light-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-regular-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-regular-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-regular-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-regular-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-regular-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-regular-webfont.woff -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-semibold-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-semibold-webfont.eot -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-semibold-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-semibold-webfont.ttf -------------------------------------------------------------------------------- /static/fonts/sourcesanspro-semibold-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/fonts/sourcesanspro-semibold-webfont.woff -------------------------------------------------------------------------------- /static/images/aboutus-hero.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/aboutus-hero.jpg -------------------------------------------------------------------------------- /static/images/console-laptop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/console-laptop.png -------------------------------------------------------------------------------- /static/images/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/favicon.ico -------------------------------------------------------------------------------- /static/images/gray-cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/gray-cloud.png -------------------------------------------------------------------------------- /static/images/img--examplesDebra.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/img--examplesDebra.png -------------------------------------------------------------------------------- /static/images/img--examplesGary.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/img--examplesGary.png -------------------------------------------------------------------------------- /static/images/img--examplesKelly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/img--examplesKelly.png -------------------------------------------------------------------------------- /static/images/img--examplesTodd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/img--examplesTodd.png -------------------------------------------------------------------------------- /static/images/logo-pcf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/logo-pcf.png -------------------------------------------------------------------------------- /static/images/logo-pws.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/logo-pws.png -------------------------------------------------------------------------------- /static/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/logo.png -------------------------------------------------------------------------------- /static/images/open-source-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/open-source-icon.png -------------------------------------------------------------------------------- /static/images/p-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/p-logo.png -------------------------------------------------------------------------------- /static/images/pivotal_footer_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/pivotal_footer_logo.png -------------------------------------------------------------------------------- /static/images/pivotal_footer_logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/pivotal_footer_logo@2x.png -------------------------------------------------------------------------------- /static/images/pui-logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/pui-logo@2x.png -------------------------------------------------------------------------------- /static/images/such-awesome.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/such-awesome.jpg -------------------------------------------------------------------------------- /static/images/we-care-sprites.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/images/we-care-sprites.png -------------------------------------------------------------------------------- /static/switchboard-header-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cloudfoundry/switchboard/a8f668525aabf2b2f79b87986b25ef62482d0049/static/switchboard-header-logo.png -------------------------------------------------------------------------------- /tools/tools.go: -------------------------------------------------------------------------------- 1 | // +build tools 2 | 3 | package tools 4 | 5 | import ( 6 | _ "github.com/maxbrunsfeld/counterfeiter/v6" 7 | _ "github.com/onsi/ginkgo/ginkgo" 8 | ) 9 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/NOTICE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2015-Present CloudFoundry.org Foundation, Inc. All Rights Reserved. 2 | 3 | This project contains software that is Copyright (c) 2014-2015 Pivotal Software, Inc. 4 | 5 | Licensed under the Apache License, Version 2.0 (the "License"); 6 | you may not use this file except in compliance with the License. 7 | You may obtain a copy of the License at 8 | 9 | http://www.apache.org/licenses/LICENSE-2.0 10 | 11 | Unless required by applicable law or agreed to in writing, software 12 | distributed under the License is distributed on an "AS IS" BASIS, 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | See the License for the specific language governing permissions and 15 | limitations under the License. 16 | 17 | This project may include a number of subcomponents with separate 18 | copyright notices and license terms. Your use of these subcomponents 19 | is subject to the terms and conditions of each subcomponent's license, 20 | as noted in the LICENSE file. 21 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/lagerctx/package.go: -------------------------------------------------------------------------------- 1 | package lagerctx // import "code.cloudfoundry.org/lager/lagerctx" 2 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/lagerflags/NOTICE: -------------------------------------------------------------------------------- 1 | CF Lager 2 | 3 | Copyright (c) 2014-Present CloudFoundry.org Foundation, Inc. All Rights Reserved. 4 | 5 | Licensed under the Apache License, Version 2.0 (the "License"); 6 | you may not use this file except in compliance with the License. 7 | You may obtain a copy of the License at 8 | 9 | http://www.apache.org/licenses/LICENSE-2.0 10 | 11 | Unless required by applicable law or agreed to in writing, software 12 | distributed under the License is distributed on an "AS IS" BASIS, 13 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | See the License for the specific language governing permissions and 15 | limitations under the License. 16 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/lagerflags/package.go: -------------------------------------------------------------------------------- 1 | package lagerflags // import "code.cloudfoundry.org/lager/lagerflags" 2 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/lagertest/package.go: -------------------------------------------------------------------------------- 1 | package lagertest // import "code.cloudfoundry.org/lager/lagertest" 2 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/package.go: -------------------------------------------------------------------------------- 1 | package lager // import "code.cloudfoundry.org/lager" 2 | -------------------------------------------------------------------------------- /vendor/code.cloudfoundry.org/lager/reconfigurable_sink.go: -------------------------------------------------------------------------------- 1 | package lager 2 | 3 | import "sync/atomic" 4 | 5 | type ReconfigurableSink struct { 6 | sink Sink 7 | 8 | minLogLevel int32 9 | } 10 | 11 | func NewReconfigurableSink(sink Sink, initialMinLogLevel LogLevel) *ReconfigurableSink { 12 | return &ReconfigurableSink{ 13 | sink: sink, 14 | 15 | minLogLevel: int32(initialMinLogLevel), 16 | } 17 | } 18 | 19 | func (sink *ReconfigurableSink) Log(log LogFormat) { 20 | minLogLevel := LogLevel(atomic.LoadInt32(&sink.minLogLevel)) 21 | 22 | if log.LogLevel < minLogLevel { 23 | return 24 | } 25 | 26 | sink.sink.Log(log) 27 | } 28 | 29 | func (sink *ReconfigurableSink) SetMinLevel(level LogLevel) { 30 | atomic.StoreInt32(&sink.minLogLevel, int32(level)) 31 | } 32 | 33 | func (sink *ReconfigurableSink) GetMinLevel() LogLevel { 34 | return LogLevel(atomic.LoadInt32(&sink.minLogLevel)) 35 | } 36 | -------------------------------------------------------------------------------- /vendor/github.com/bmizerany/pat/.gitignore: -------------------------------------------------------------------------------- 1 | *.prof 2 | *.out 3 | example/example 4 | -------------------------------------------------------------------------------- /vendor/github.com/cloudfoundry-incubator/galera-healthcheck/NOTICE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2015-Present CloudFoundry.org Foundation, Inc. All Rights Reserved. 2 | 3 | This project contains software that is Copyright (c) 2012-2015 Pivotal Software, Inc. 4 | 5 | This project is licensed to you under the Apache License, Version 2.0 (the "License"). 6 | 7 | You may not use this project except in compliance with the License. 8 | 9 | This project may include a number of subcomponents with separate copyright notices 10 | and license terms. Your use of these subcomponents is subject to the terms and 11 | conditions of the subcomponent's license, as noted in the LICENSE file. 12 | -------------------------------------------------------------------------------- /vendor/github.com/cloudfoundry-incubator/galera-healthcheck/api/middleware/basic_auth.go: -------------------------------------------------------------------------------- 1 | package middleware 2 | 3 | import ( 4 | "crypto/subtle" 5 | "net/http" 6 | ) 7 | 8 | type BasicAuth struct { 9 | Username, Password string 10 | } 11 | 12 | func NewBasicAuth(username, password string) Middleware { 13 | return BasicAuth{ 14 | Username: username, 15 | Password: password, 16 | } 17 | } 18 | 19 | func (b BasicAuth) Wrap(next http.Handler) http.Handler { 20 | handler := http.HandlerFunc(func(rw http.ResponseWriter, req *http.Request) { 21 | username, password, ok := req.BasicAuth() 22 | if ok && 23 | secureCompare(username, b.Username) && 24 | secureCompare(password, b.Password) { 25 | next.ServeHTTP(rw, req) 26 | } else { 27 | rw.Header().Set("WWW-Authenticate", "Basic realm=\"Authorization Required\"") 28 | http.Error(rw, "Not Authorized", http.StatusUnauthorized) 29 | } 30 | }) 31 | return handler 32 | } 33 | 34 | func secureCompare(a, b string) bool { 35 | x := []byte(a) 36 | y := []byte(b) 37 | return subtle.ConstantTimeCompare(x, y) == 1 38 | } 39 | -------------------------------------------------------------------------------- /vendor/github.com/cloudfoundry-incubator/galera-healthcheck/api/middleware/middleware.go: -------------------------------------------------------------------------------- 1 | package middleware 2 | 3 | import "net/http" 4 | 5 | type Middleware interface { 6 | Wrap(http.Handler) http.Handler 7 | } 8 | -------------------------------------------------------------------------------- /vendor/github.com/cloudfoundry-incubator/galera-healthcheck/domain/db_state.go: -------------------------------------------------------------------------------- 1 | package domain 2 | 3 | import "fmt" 4 | 5 | type WsrepLocalState uint 6 | type WsrepLocalStateComment string 7 | 8 | const ( 9 | Joining WsrepLocalState = iota + 1 // https://splice.com/blog/iota-elegant-constants-golang/ 10 | DonorDesynced 11 | Joined 12 | Synced 13 | 14 | JoiningString = WsrepLocalStateComment("Joining") 15 | DonorDesyncedString = WsrepLocalStateComment("Donor/Desynced") 16 | JoinedString = WsrepLocalStateComment("Joined") 17 | SyncedString = WsrepLocalStateComment("Synced") 18 | ) 19 | 20 | type DBState struct { 21 | WsrepLocalIndex uint 22 | WsrepLocalState WsrepLocalState 23 | ReadOnly bool 24 | } 25 | 26 | func (w WsrepLocalState) Comment() WsrepLocalStateComment { 27 | switch w { 28 | case Joining: 29 | return JoiningString 30 | case DonorDesynced: 31 | return DonorDesyncedString 32 | case Joined: 33 | return JoinedString 34 | case Synced: 35 | return SyncedString 36 | default: 37 | return WsrepLocalStateComment(fmt.Sprintf("Unrecognized state: %d", w)) 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*.go] 4 | indent_style = tab 5 | indent_size = 4 6 | insert_final_newline = true 7 | 8 | [*.{yml,yaml}] 9 | indent_style = space 10 | indent_size = 2 11 | insert_final_newline = true 12 | trim_trailing_whitespace = true 13 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/.gitattributes: -------------------------------------------------------------------------------- 1 | go.sum linguist-generated 2 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/.gitignore: -------------------------------------------------------------------------------- 1 | # Setup a Global .gitignore for OS and editor generated files: 2 | # https://help.github.com/articles/ignoring-files 3 | # git config --global core.excludesfile ~/.gitignore_global 4 | 5 | .vagrant 6 | *.sublime-project 7 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/.mailmap: -------------------------------------------------------------------------------- 1 | Chris Howey 2 | Nathan Youngman <4566+nathany@users.noreply.github.com> 3 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/fen.go: -------------------------------------------------------------------------------- 1 | // Copyright 2010 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build solaris 6 | // +build solaris 7 | 8 | package fsnotify 9 | 10 | import ( 11 | "errors" 12 | ) 13 | 14 | // Watcher watches a set of files, delivering events to a channel. 15 | type Watcher struct { 16 | Events chan Event 17 | Errors chan error 18 | } 19 | 20 | // NewWatcher establishes a new watcher with the underlying OS and begins waiting for events. 21 | func NewWatcher() (*Watcher, error) { 22 | return nil, errors.New("FEN based watcher not yet supported for fsnotify\n") 23 | } 24 | 25 | // Close removes all watches and closes the events channel. 26 | func (w *Watcher) Close() error { 27 | return nil 28 | } 29 | 30 | // Add starts watching the named file or directory (non-recursively). 31 | func (w *Watcher) Add(name string) error { 32 | return nil 33 | } 34 | 35 | // Remove stops watching the the named file or directory (non-recursively). 36 | func (w *Watcher) Remove(name string) error { 37 | return nil 38 | } 39 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/fsnotify/fsnotify 2 | 3 | go 1.13 4 | 5 | require golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c 6 | 7 | retract v1.5.0 8 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/go.sum: -------------------------------------------------------------------------------- 1 | golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c h1:F1jZWGFhYfh0Ci55sIpILtKKK8p3i2/krTr0H1rg74I= 2 | golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= 3 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/open_mode_bsd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build freebsd || openbsd || netbsd || dragonfly 6 | // +build freebsd openbsd netbsd dragonfly 7 | 8 | package fsnotify 9 | 10 | import "golang.org/x/sys/unix" 11 | 12 | const openMode = unix.O_NONBLOCK | unix.O_RDONLY | unix.O_CLOEXEC 13 | -------------------------------------------------------------------------------- /vendor/github.com/fsnotify/fsnotify/open_mode_darwin.go: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build darwin 6 | // +build darwin 7 | 8 | package fsnotify 9 | 10 | import "golang.org/x/sys/unix" 11 | 12 | // note: this constant is not defined on BSD 13 | const openMode = unix.O_EVTONLY | unix.O_CLOEXEC 14 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | 3 | root = true 4 | 5 | [*] 6 | insert_final_newline = true 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | indent_style = tab 10 | indent_size = 8 11 | 12 | [*.{md,yml,yaml,json}] 13 | indent_style = space 14 | indent_size = 2 15 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto 2 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/.gitignore: -------------------------------------------------------------------------------- 1 | vendor/ 2 | /.glide 3 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/Taskfile.yml: -------------------------------------------------------------------------------- 1 | # https://taskfile.dev 2 | 3 | version: '2' 4 | 5 | tasks: 6 | default: 7 | cmds: 8 | - task: test 9 | 10 | test: 11 | cmds: 12 | - go test -v . 13 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/crypto.go: -------------------------------------------------------------------------------- 1 | package sprig 2 | 3 | import ( 4 | "crypto/sha1" 5 | "crypto/sha256" 6 | "encoding/hex" 7 | "fmt" 8 | "hash/adler32" 9 | ) 10 | 11 | func sha256sum(input string) string { 12 | hash := sha256.Sum256([]byte(input)) 13 | return hex.EncodeToString(hash[:]) 14 | } 15 | 16 | func sha1sum(input string) string { 17 | hash := sha1.Sum([]byte(input)) 18 | return hex.EncodeToString(hash[:]) 19 | } 20 | 21 | func adler32sum(input string) string { 22 | hash := adler32.Checksum([]byte(input)) 23 | return fmt.Sprintf("%d", hash) 24 | } 25 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/doc.go: -------------------------------------------------------------------------------- 1 | /* 2 | Package sprig provides template functions for Go. 3 | 4 | This package contains a number of utility functions for working with data 5 | inside of Go `html/template` and `text/template` files. 6 | 7 | To add these functions, use the `template.Funcs()` method: 8 | 9 | t := templates.New("foo").Funcs(sprig.FuncMap()) 10 | 11 | Note that you should add the function map before you parse any template files. 12 | 13 | In several cases, Sprig reverses the order of arguments from the way they 14 | appear in the standard library. This is to make it easier to pipe 15 | arguments into functions. 16 | 17 | See http://masterminds.github.io/sprig/ for more detailed documentation on each of the available functions. 18 | */ 19 | package sprig 20 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/go-task/slim-sprig 2 | 3 | go 1.13 4 | 5 | require ( 6 | github.com/davecgh/go-spew v1.1.1 // indirect 7 | github.com/stretchr/testify v1.5.1 8 | ) 9 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/network.go: -------------------------------------------------------------------------------- 1 | package sprig 2 | 3 | import ( 4 | "math/rand" 5 | "net" 6 | ) 7 | 8 | func getHostByName(name string) string { 9 | addrs, _ := net.LookupHost(name) 10 | //TODO: add error handing when release v3 comes out 11 | return addrs[rand.Intn(len(addrs))] 12 | } 13 | -------------------------------------------------------------------------------- /vendor/github.com/go-task/slim-sprig/reflect.go: -------------------------------------------------------------------------------- 1 | package sprig 2 | 3 | import ( 4 | "fmt" 5 | "reflect" 6 | ) 7 | 8 | // typeIs returns true if the src is the type named in target. 9 | func typeIs(target string, src interface{}) bool { 10 | return target == typeOf(src) 11 | } 12 | 13 | func typeIsLike(target string, src interface{}) bool { 14 | t := typeOf(src) 15 | return target == t || "*"+target == t 16 | } 17 | 18 | func typeOf(src interface{}) string { 19 | return fmt.Sprintf("%T", src) 20 | } 21 | 22 | func kindIs(target string, src interface{}) bool { 23 | return target == kindOf(src) 24 | } 25 | 26 | func kindOf(src interface{}) string { 27 | return reflect.ValueOf(src).Kind().String() 28 | } 29 | -------------------------------------------------------------------------------- /vendor/github.com/golang/protobuf/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/github.com/golang/protobuf/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/github.com/imdario/mergo/.deepsource.toml: -------------------------------------------------------------------------------- 1 | version = 1 2 | 3 | test_patterns = [ 4 | "*_test.go" 5 | ] 6 | 7 | [[analyzers]] 8 | name = "go" 9 | enabled = true 10 | 11 | [analyzers.meta] 12 | import_path = "github.com/imdario/mergo" -------------------------------------------------------------------------------- /vendor/github.com/imdario/mergo/.gitignore: -------------------------------------------------------------------------------- 1 | #### joe made this: http://goel.io/joe 2 | 3 | #### go #### 4 | # Binaries for programs and plugins 5 | *.exe 6 | *.dll 7 | *.so 8 | *.dylib 9 | 10 | # Test binary, build with `go test -c` 11 | *.test 12 | 13 | # Output of the go coverage tool, specifically when used with LiteIDE 14 | *.out 15 | 16 | # Project-local glide cache, RE: https://github.com/Masterminds/glide/issues/736 17 | .glide/ 18 | 19 | #### vim #### 20 | # Swap 21 | [._]*.s[a-v][a-z] 22 | [._]*.sw[a-p] 23 | [._]s[a-v][a-z] 24 | [._]sw[a-p] 25 | 26 | # Session 27 | Session.vim 28 | 29 | # Temporary 30 | .netrwhist 31 | *~ 32 | # Auto-generated tag files 33 | tags 34 | -------------------------------------------------------------------------------- /vendor/github.com/imdario/mergo/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | arch: 3 | - amd64 4 | - ppc64le 5 | install: 6 | - go get -t 7 | - go get golang.org/x/tools/cmd/cover 8 | - go get github.com/mattn/goveralls 9 | script: 10 | - go test -race -v ./... 11 | after_script: 12 | - $HOME/gopath/bin/goveralls -service=travis-ci -repotoken $COVERALLS_TOKEN 13 | -------------------------------------------------------------------------------- /vendor/github.com/imdario/mergo/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/imdario/mergo 2 | 3 | go 1.13 4 | 5 | require gopkg.in/yaml.v2 v2.3.0 6 | -------------------------------------------------------------------------------- /vendor/github.com/imdario/mergo/go.sum: -------------------------------------------------------------------------------- 1 | gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= 2 | gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= 3 | gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= 4 | gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= 5 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.iml 25 | .idea 26 | .envrc 27 | 28 | /counterfeiter 29 | integration/testdata/output 30 | *.profile 31 | *.bench 32 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | matrix: 4 | include: 5 | - go: "1.11.x" 6 | script: scripts/ci.sh 7 | - go: "1.12.x" 8 | script: scripts/ci.sh 9 | 10 | env: 11 | - GO111MODULE=on 12 | 13 | install: true 14 | 15 | sudo: false 16 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/appveyor.yml: -------------------------------------------------------------------------------- 1 | platform: x64 2 | shallow_clone: true 3 | clone_depth: 10 4 | clone_folder: c:\projects\counterfeiter 5 | 6 | environment: 7 | GOPATH: c:\gopath 8 | 9 | test_script: 10 | - cd c:\projects\counterfeiter 11 | - set PATH=c:\gopath\bin;c:\go\bin;C:\mingw-w64\x86_64-7.2.0-posix-seh-rt_v5-rev1\mingw64\bin;%PATH% 12 | - echo %PATH% 13 | - go version 14 | - go env 15 | - go vet ./... 16 | - go install . 17 | - copy scripts\counterfeiter.bat c:\gopath\bin 18 | - go generate ./... 19 | - go build -v ./... 20 | - go test -v -race ./... 21 | 22 | build: off 23 | deploy: off 24 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/arguments/files.go: -------------------------------------------------------------------------------- 1 | package arguments 2 | 3 | import "os" 4 | 5 | type Evaler func(string) (string, error) 6 | type Stater func(string) (os.FileInfo, error) 7 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/generator/cache.go: -------------------------------------------------------------------------------- 1 | package generator 2 | 3 | import "golang.org/x/tools/go/packages" 4 | 5 | type Cache struct { 6 | packageMap map[string]interface{} 7 | } 8 | 9 | type FakeCache struct{} 10 | 11 | func (c *FakeCache) Load(packagePath string) ([]*packages.Package, bool) { return nil, false } 12 | func (c *FakeCache) Store(packagePath string, packages []*packages.Package) {} 13 | 14 | type Cacher interface { 15 | Load(packagePath string) ([]*packages.Package, bool) 16 | Store(packagePath string, packages []*packages.Package) 17 | } 18 | 19 | func (c *Cache) Load(packagePath string) ([]*packages.Package, bool) { 20 | p, ok := c.packageMap[packagePath] 21 | if !ok { 22 | return nil, false 23 | } 24 | packages, ok := p.([]*packages.Package) 25 | return packages, ok 26 | } 27 | 28 | func (c *Cache) Store(packagePath string, packages []*packages.Package) { 29 | if c.packageMap == nil { 30 | c.packageMap = map[string]interface{}{} 31 | } 32 | c.packageMap[packagePath] = packages 33 | } 34 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/generator/function_loader.go: -------------------------------------------------------------------------------- 1 | package generator 2 | 3 | import ( 4 | "errors" 5 | "go/types" 6 | ) 7 | 8 | func (f *Fake) loadMethodForFunction() error { 9 | t, ok := f.Target.Type().(*types.Named) 10 | if !ok { 11 | return errors.New("target is not a named type") 12 | } 13 | sig, ok := t.Underlying().(*types.Signature) 14 | if !ok { 15 | return errors.New("target does not have an underlying function signature") 16 | } 17 | f.addTypesForMethod(sig) 18 | f.Function = methodForSignature(sig, f.TargetName, f.Imports) 19 | return nil 20 | } 21 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/generator/package_loader.go: -------------------------------------------------------------------------------- 1 | package generator 2 | 3 | import ( 4 | "go/types" 5 | 6 | "golang.org/x/tools/go/packages" 7 | ) 8 | 9 | type rawMethod struct { 10 | Func *types.Func 11 | Signature *types.Signature 12 | } 13 | 14 | // packageMethodSet identifies the functions that are exported from a given 15 | // package. 16 | func packageMethodSet(p *packages.Package) []*rawMethod { 17 | if p == nil || p.Types == nil || p.Types.Scope() == nil { 18 | return nil 19 | } 20 | var result []*rawMethod 21 | scope := p.Types.Scope() 22 | for _, name := range scope.Names() { 23 | obj := scope.Lookup(name) 24 | if !obj.Exported() { 25 | continue // skip unexported names 26 | } 27 | fun, ok := obj.(*types.Func) 28 | if !ok { 29 | continue 30 | } 31 | sig, ok := obj.Type().(*types.Signature) 32 | if !ok { 33 | continue 34 | } 35 | result = append(result, &rawMethod{ 36 | Func: fun, 37 | Signature: sig, 38 | }) 39 | } 40 | 41 | return result 42 | } 43 | -------------------------------------------------------------------------------- /vendor/github.com/maxbrunsfeld/counterfeiter/v6/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/maxbrunsfeld/counterfeiter/v6 2 | 3 | require ( 4 | github.com/golang/protobuf v1.3.1 // indirect 5 | github.com/joefitzgerald/rainbow-reporter v0.1.0 6 | github.com/kr/pretty v0.1.0 // indirect 7 | github.com/onsi/ginkgo v1.8.0 // indirect 8 | github.com/onsi/gomega v1.9.0 9 | github.com/sclevine/spec v1.4.0 10 | golang.org/x/net v0.0.0-20190628185345-da137c7871d7 // indirect 11 | golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb // indirect 12 | golang.org/x/text v0.3.2 // indirect 13 | golang.org/x/tools v0.0.0-20200301222351-066e0c02454c 14 | gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 // indirect 15 | ) 16 | 17 | go 1.11 18 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/.gitignore: -------------------------------------------------------------------------------- 1 | .idea/ 2 | .test/ 3 | examples/_* -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM golang 2 | 3 | RUN mkdir -p $GOPATH/src/github.com/nxadm/tail/ 4 | ADD . $GOPATH/src/github.com/nxadm/tail/ 5 | 6 | # expecting to fetch dependencies successfully. 7 | RUN go get -v github.com/nxadm/tail 8 | 9 | # expecting to run the test successfully. 10 | RUN go test -v github.com/nxadm/tail 11 | 12 | # expecting to install successfully 13 | RUN go install -v github.com/nxadm/tail 14 | RUN go install -v github.com/nxadm/tail/cmd/gotail 15 | 16 | RUN $GOPATH/bin/gotail -h || true 17 | 18 | ENV PATH $GOPATH/bin:$PATH 19 | CMD ["gotail"] 20 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/nxadm/tail 2 | 3 | go 1.13 4 | 5 | require ( 6 | github.com/fsnotify/fsnotify v1.4.9 7 | gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 8 | ) 9 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/go.sum: -------------------------------------------------------------------------------- 1 | github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4= 2 | github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= 3 | golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9 h1:L2auWcuQIvxz9xSEqzESnV/QN/gNRXNApHi3fYwl2w0= 4 | golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 5 | gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= 6 | gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= 7 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/ratelimiter/Licence: -------------------------------------------------------------------------------- 1 | Copyright (C) 2013 99designs 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 4 | 5 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 6 | 7 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 8 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/ratelimiter/storage.go: -------------------------------------------------------------------------------- 1 | package ratelimiter 2 | 3 | type Storage interface { 4 | GetBucketFor(string) (*LeakyBucket, error) 5 | SetBucketFor(string, LeakyBucket) error 6 | } 7 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/tail_posix.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail 2 | // +build !windows 3 | 4 | package tail 5 | 6 | import ( 7 | "os" 8 | ) 9 | 10 | // Deprecated: this function is only useful internally and, as such, 11 | // it will be removed from the API in a future major release. 12 | // 13 | // OpenFile proxies a os.Open call for a file so it can be correctly tailed 14 | // on POSIX and non-POSIX OSes like MS Windows. 15 | func OpenFile(name string) (file *os.File, err error) { 16 | return os.Open(name) 17 | } 18 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/tail_windows.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail 2 | // +build windows 3 | 4 | package tail 5 | 6 | import ( 7 | "os" 8 | 9 | "github.com/nxadm/tail/winfile" 10 | ) 11 | 12 | // Deprecated: this function is only useful internally and, as such, 13 | // it will be removed from the API in a future major release. 14 | // 15 | // OpenFile proxies a os.Open call for a file so it can be correctly tailed 16 | // on POSIX and non-POSIX OSes like MS Windows. 17 | func OpenFile(name string) (file *os.File, err error) { 18 | return winfile.OpenFile(name, os.O_RDONLY, 0) 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/nxadm/tail/watch/watch.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2019 FOSS contributors of https://github.com/nxadm/tail 2 | // Copyright (c) 2015 HPE Software Inc. All rights reserved. 3 | // Copyright (c) 2013 ActiveState Software Inc. All rights reserved. 4 | 5 | package watch 6 | 7 | import "gopkg.in/tomb.v1" 8 | 9 | // FileWatcher monitors file-level events. 10 | type FileWatcher interface { 11 | // BlockUntilExists blocks until the file comes into existence. 12 | BlockUntilExists(*tomb.Tomb) error 13 | 14 | // ChangeEvents reports on changes to a file, be it modification, 15 | // deletion, renames or truncations. Returned FileChanges group of 16 | // channels will be closed, thus become unusable, after a deletion 17 | // or truncation event. 18 | // In order to properly report truncations, ChangeEvents requires 19 | // the caller to pass their current offset in the file. 20 | ChangeEvents(*tomb.Tomb, int64) (*FileChanges, error) 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | TODO 3 | tmp/**/* 4 | *.coverprofile 5 | .vscode 6 | .idea/ 7 | *.log 8 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - tip 4 | - 1.16.x 5 | - 1.15.x 6 | 7 | cache: 8 | directories: 9 | - $GOPATH/pkg/mod 10 | 11 | # allow internal package imports, necessary for forked repositories 12 | go_import_path: github.com/onsi/ginkgo 13 | 14 | install: 15 | - GO111MODULE="off" go get -v -t ./... 16 | - GO111MODULE="off" go get golang.org/x/tools/cmd/cover 17 | - GO111MODULE="off" go get github.com/onsi/gomega 18 | - GO111MODULE="off" go install github.com/onsi/ginkgo/ginkgo 19 | - export PATH=$GOPATH/bin:$PATH 20 | 21 | script: 22 | - GO111MODULE="on" go mod tidy && git diff --exit-code go.mod go.sum 23 | - go vet 24 | - ginkgo -r --randomizeAllSpecs --randomizeSuites --race --trace 25 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/RELEASING.md: -------------------------------------------------------------------------------- 1 | A Ginkgo release is a tagged git sha and a GitHub release. To cut a release: 2 | 3 | 1. Ensure CHANGELOG.md is up to date. 4 | - Use `git log --pretty=format:'- %s [%h]' HEAD...vX.X.X` to list all the commits since the last release 5 | - Categorize the changes into 6 | - Breaking Changes (requires a major version) 7 | - New Features (minor version) 8 | - Fixes (fix version) 9 | - Maintenance (which in general should not be mentioned in `CHANGELOG.md` as they have no user impact) 10 | 1. Update `VERSION` in `config/config.go` 11 | 1. Commit, push, and release: 12 | ``` 13 | git commit -m "vM.m.p" 14 | git push 15 | gh release create "vM.m.p" 16 | git fetch --tags origin master 17 | ``` -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/help_command.go: -------------------------------------------------------------------------------- 1 | package main 2 | 3 | import ( 4 | "flag" 5 | "fmt" 6 | ) 7 | 8 | func BuildHelpCommand() *Command { 9 | return &Command{ 10 | Name: "help", 11 | FlagSet: flag.NewFlagSet("help", flag.ExitOnError), 12 | UsageCommand: "ginkgo help ", 13 | Usage: []string{ 14 | "Print usage information. If a command is passed in, print usage information just for that command.", 15 | }, 16 | Command: printHelp, 17 | } 18 | } 19 | 20 | func printHelp(args []string, additionalArgs []string) { 21 | if len(args) == 0 { 22 | usage() 23 | } else { 24 | command, found := commandMatching(args[0]) 25 | if !found { 26 | complainAndQuit(fmt.Sprintf("Unknown command: %s", args[0])) 27 | } 28 | 29 | usageForCommand(command, true) 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/interrupthandler/interrupt_handler.go: -------------------------------------------------------------------------------- 1 | package interrupthandler 2 | 3 | import ( 4 | "os" 5 | "os/signal" 6 | "sync" 7 | "syscall" 8 | ) 9 | 10 | type InterruptHandler struct { 11 | interruptCount int 12 | lock *sync.Mutex 13 | C chan bool 14 | } 15 | 16 | func NewInterruptHandler() *InterruptHandler { 17 | h := &InterruptHandler{ 18 | lock: &sync.Mutex{}, 19 | C: make(chan bool), 20 | } 21 | 22 | go h.handleInterrupt() 23 | SwallowSigQuit() 24 | 25 | return h 26 | } 27 | 28 | func (h *InterruptHandler) WasInterrupted() bool { 29 | h.lock.Lock() 30 | defer h.lock.Unlock() 31 | 32 | return h.interruptCount > 0 33 | } 34 | 35 | func (h *InterruptHandler) handleInterrupt() { 36 | c := make(chan os.Signal, 1) 37 | signal.Notify(c, os.Interrupt, syscall.SIGTERM) 38 | 39 | <-c 40 | signal.Stop(c) 41 | 42 | h.lock.Lock() 43 | h.interruptCount++ 44 | if h.interruptCount == 1 { 45 | close(h.C) 46 | } else if h.interruptCount > 5 { 47 | os.Exit(1) 48 | } 49 | h.lock.Unlock() 50 | 51 | go h.handleInterrupt() 52 | } 53 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/interrupthandler/sigquit_swallower_unix.go: -------------------------------------------------------------------------------- 1 | // +build freebsd openbsd netbsd dragonfly darwin linux solaris 2 | 3 | package interrupthandler 4 | 5 | import ( 6 | "os" 7 | "os/signal" 8 | "syscall" 9 | ) 10 | 11 | func SwallowSigQuit() { 12 | c := make(chan os.Signal, 1024) 13 | signal.Notify(c, syscall.SIGQUIT) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/interrupthandler/sigquit_swallower_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package interrupthandler 4 | 5 | func SwallowSigQuit() { 6 | //noop 7 | } 8 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/testrunner/build_args.go: -------------------------------------------------------------------------------- 1 | // +build go1.10 2 | 3 | package testrunner 4 | 5 | var ( 6 | buildArgs = []string{"test", "-c"} 7 | ) 8 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/testrunner/build_args_old.go: -------------------------------------------------------------------------------- 1 | // +build !go1.10 2 | 3 | package testrunner 4 | 5 | var ( 6 | buildArgs = []string{"test", "-c", "-i"} 7 | ) 8 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/testrunner/run_result.go: -------------------------------------------------------------------------------- 1 | package testrunner 2 | 3 | type RunResult struct { 4 | Passed bool 5 | HasProgrammaticFocus bool 6 | } 7 | 8 | func PassingRunResult() RunResult { 9 | return RunResult{ 10 | Passed: true, 11 | HasProgrammaticFocus: false, 12 | } 13 | } 14 | 15 | func FailingRunResult() RunResult { 16 | return RunResult{ 17 | Passed: false, 18 | HasProgrammaticFocus: false, 19 | } 20 | } 21 | 22 | func (r RunResult) Merge(o RunResult) RunResult { 23 | return RunResult{ 24 | Passed: r.Passed && o.Passed, 25 | HasProgrammaticFocus: r.HasProgrammaticFocus || o.HasProgrammaticFocus, 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/testsuite/vendor_check_go15.go: -------------------------------------------------------------------------------- 1 | // +build !go1.6 2 | 3 | package testsuite 4 | 5 | import ( 6 | "os" 7 | "path" 8 | ) 9 | 10 | // "This change will only be enabled if the go command is run with 11 | // GO15VENDOREXPERIMENT=1 in its environment." 12 | // c.f. the vendor-experiment proposal https://goo.gl/2ucMeC 13 | func vendorExperimentCheck(dir string) bool { 14 | vendorExperiment := os.Getenv("GO15VENDOREXPERIMENT") 15 | return vendorExperiment == "1" && path.Base(dir) == "vendor" 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/testsuite/vendor_check_go16.go: -------------------------------------------------------------------------------- 1 | // +build go1.6 2 | 3 | package testsuite 4 | 5 | import ( 6 | "os" 7 | "path" 8 | ) 9 | 10 | // in 1.6 the vendor directory became the default go behaviour, so now 11 | // check if its disabled. 12 | func vendorExperimentCheck(dir string) bool { 13 | vendorExperiment := os.Getenv("GO15VENDOREXPERIMENT") 14 | return vendorExperiment != "0" && path.Base(dir) == "vendor" 15 | } 16 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/version_command.go: -------------------------------------------------------------------------------- 1 | package main 2 | 3 | import ( 4 | "flag" 5 | "fmt" 6 | 7 | "github.com/onsi/ginkgo/config" 8 | ) 9 | 10 | func BuildVersionCommand() *Command { 11 | return &Command{ 12 | Name: "version", 13 | FlagSet: flag.NewFlagSet("version", flag.ExitOnError), 14 | UsageCommand: "ginkgo version", 15 | Usage: []string{ 16 | "Print Ginkgo's version", 17 | }, 18 | Command: printVersion, 19 | } 20 | } 21 | 22 | func printVersion([]string, []string) { 23 | fmt.Printf("Ginkgo Version %s\n", config.VERSION) 24 | } 25 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/ginkgo/watch/delta.go: -------------------------------------------------------------------------------- 1 | package watch 2 | 3 | import "sort" 4 | 5 | type Delta struct { 6 | ModifiedPackages []string 7 | 8 | NewSuites []*Suite 9 | RemovedSuites []*Suite 10 | modifiedSuites []*Suite 11 | } 12 | 13 | type DescendingByDelta []*Suite 14 | 15 | func (a DescendingByDelta) Len() int { return len(a) } 16 | func (a DescendingByDelta) Swap(i, j int) { a[i], a[j] = a[j], a[i] } 17 | func (a DescendingByDelta) Less(i, j int) bool { return a[i].Delta() > a[j].Delta() } 18 | 19 | func (d Delta) ModifiedSuites() []*Suite { 20 | sort.Sort(DescendingByDelta(d.modifiedSuites)) 21 | return d.modifiedSuites 22 | } 23 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/onsi/ginkgo 2 | 3 | go 1.15 4 | 5 | require ( 6 | github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0 7 | github.com/nxadm/tail v1.4.8 8 | github.com/onsi/gomega v1.10.1 9 | golang.org/x/sys v0.0.0-20210112080510-489259a85091 10 | golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e 11 | ) 12 | 13 | retract v1.16.3 // git tag accidentally associated with incorrect git commit 14 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/global/init.go: -------------------------------------------------------------------------------- 1 | package global 2 | 3 | import ( 4 | "time" 5 | 6 | "github.com/onsi/ginkgo/internal/failer" 7 | "github.com/onsi/ginkgo/internal/suite" 8 | ) 9 | 10 | const DefaultTimeout = time.Duration(1 * time.Second) 11 | 12 | var Suite *suite.Suite 13 | var Failer *failer.Failer 14 | 15 | func init() { 16 | InitializeGlobals() 17 | } 18 | 19 | func InitializeGlobals() { 20 | Failer = failer.New() 21 | Suite = suite.New(Failer) 22 | } 23 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/leafnodes/interfaces.go: -------------------------------------------------------------------------------- 1 | package leafnodes 2 | 3 | import ( 4 | "github.com/onsi/ginkgo/types" 5 | ) 6 | 7 | type BasicNode interface { 8 | Type() types.SpecComponentType 9 | Run() (types.SpecState, types.SpecFailure) 10 | CodeLocation() types.CodeLocation 11 | } 12 | 13 | type SubjectNode interface { 14 | BasicNode 15 | 16 | Text() string 17 | Flag() types.FlagType 18 | Samples() int 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/remote/output_interceptor.go: -------------------------------------------------------------------------------- 1 | package remote 2 | 3 | import "os" 4 | 5 | /* 6 | The OutputInterceptor is used by the ForwardingReporter to 7 | intercept and capture all stdin and stderr output during a test run. 8 | */ 9 | type OutputInterceptor interface { 10 | StartInterceptingOutput() error 11 | StopInterceptingAndReturnOutput() (string, error) 12 | StreamTo(*os.File) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/remote/output_interceptor_win.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | 3 | package remote 4 | 5 | import ( 6 | "errors" 7 | "os" 8 | ) 9 | 10 | func NewOutputInterceptor() OutputInterceptor { 11 | return &outputInterceptor{} 12 | } 13 | 14 | type outputInterceptor struct { 15 | intercepting bool 16 | } 17 | 18 | func (interceptor *outputInterceptor) StartInterceptingOutput() error { 19 | if interceptor.intercepting { 20 | return errors.New("Already intercepting output!") 21 | } 22 | interceptor.intercepting = true 23 | 24 | // not working on windows... 25 | 26 | return nil 27 | } 28 | 29 | func (interceptor *outputInterceptor) StopInterceptingAndReturnOutput() (string, error) { 30 | // not working on windows... 31 | interceptor.intercepting = false 32 | 33 | return "", nil 34 | } 35 | 36 | func (interceptor *outputInterceptor) StreamTo(*os.File) {} 37 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/spec_iterator/serial_spec_iterator.go: -------------------------------------------------------------------------------- 1 | package spec_iterator 2 | 3 | import ( 4 | "github.com/onsi/ginkgo/internal/spec" 5 | ) 6 | 7 | type SerialIterator struct { 8 | specs []*spec.Spec 9 | index int 10 | } 11 | 12 | func NewSerialIterator(specs []*spec.Spec) *SerialIterator { 13 | return &SerialIterator{ 14 | specs: specs, 15 | index: 0, 16 | } 17 | } 18 | 19 | func (s *SerialIterator) Next() (*spec.Spec, error) { 20 | if s.index >= len(s.specs) { 21 | return nil, ErrClosed 22 | } 23 | 24 | spec := s.specs[s.index] 25 | s.index += 1 26 | return spec, nil 27 | } 28 | 29 | func (s *SerialIterator) NumberOfSpecsPriorToIteration() int { 30 | return len(s.specs) 31 | } 32 | 33 | func (s *SerialIterator) NumberOfSpecsToProcessIfKnown() (int, bool) { 34 | return len(s.specs), true 35 | } 36 | 37 | func (s *SerialIterator) NumberOfSpecsThatWillBeRunIfKnown() (int, bool) { 38 | count := 0 39 | for _, s := range s.specs { 40 | if !s.Skipped() && !s.Pending() { 41 | count += 1 42 | } 43 | } 44 | return count, true 45 | } 46 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/spec_iterator/spec_iterator.go: -------------------------------------------------------------------------------- 1 | package spec_iterator 2 | 3 | import ( 4 | "errors" 5 | 6 | "github.com/onsi/ginkgo/internal/spec" 7 | ) 8 | 9 | var ErrClosed = errors.New("no more specs to run") 10 | 11 | type SpecIterator interface { 12 | Next() (*spec.Spec, error) 13 | NumberOfSpecsPriorToIteration() int 14 | NumberOfSpecsToProcessIfKnown() (int, bool) 15 | NumberOfSpecsThatWillBeRunIfKnown() (int, bool) 16 | } 17 | 18 | type Counter struct { 19 | Index int `json:"index"` 20 | } 21 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/specrunner/random_id.go: -------------------------------------------------------------------------------- 1 | package specrunner 2 | 3 | import ( 4 | "crypto/rand" 5 | "fmt" 6 | ) 7 | 8 | func randomID() string { 9 | b := make([]byte, 8) 10 | _, err := rand.Read(b) 11 | if err != nil { 12 | return "" 13 | } 14 | return fmt.Sprintf("%x-%x-%x-%x", b[0:2], b[2:4], b[4:6], b[6:8]) 15 | } 16 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/internal/writer/fake_writer.go: -------------------------------------------------------------------------------- 1 | package writer 2 | 3 | type FakeGinkgoWriter struct { 4 | EventStream []string 5 | } 6 | 7 | func NewFake() *FakeGinkgoWriter { 8 | return &FakeGinkgoWriter{ 9 | EventStream: []string{}, 10 | } 11 | } 12 | 13 | func (writer *FakeGinkgoWriter) AddEvent(event string) { 14 | writer.EventStream = append(writer.EventStream, event) 15 | } 16 | 17 | func (writer *FakeGinkgoWriter) Truncate() { 18 | writer.EventStream = append(writer.EventStream, "TRUNCATE") 19 | } 20 | 21 | func (writer *FakeGinkgoWriter) DumpOut() { 22 | writer.EventStream = append(writer.EventStream, "DUMP") 23 | } 24 | 25 | func (writer *FakeGinkgoWriter) DumpOutWithHeader(header string) { 26 | writer.EventStream = append(writer.EventStream, "DUMP_WITH_HEADER: "+header) 27 | } 28 | 29 | func (writer *FakeGinkgoWriter) Bytes() []byte { 30 | writer.EventStream = append(writer.EventStream, "BYTES") 31 | return nil 32 | } 33 | 34 | func (writer *FakeGinkgoWriter) Write(data []byte) (n int, err error) { 35 | return 0, nil 36 | } 37 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/reporter.go: -------------------------------------------------------------------------------- 1 | package reporters 2 | 3 | import ( 4 | "github.com/onsi/ginkgo/config" 5 | "github.com/onsi/ginkgo/types" 6 | ) 7 | 8 | type Reporter interface { 9 | SpecSuiteWillBegin(config config.GinkgoConfigType, summary *types.SuiteSummary) 10 | BeforeSuiteDidRun(setupSummary *types.SetupSummary) 11 | SpecWillRun(specSummary *types.SpecSummary) 12 | SpecDidComplete(specSummary *types.SpecSummary) 13 | AfterSuiteDidRun(setupSummary *types.SetupSummary) 14 | SpecSuiteDidEnd(summary *types.SuiteSummary) 15 | } 16 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-colorable/README.md: -------------------------------------------------------------------------------- 1 | # go-colorable 2 | 3 | Colorable writer for windows. 4 | 5 | For example, most of logger packages doesn't show colors on windows. (I know we can do it with ansicon. But I don't want.) 6 | This package is possible to handle escape sequence for ansi color on windows. 7 | 8 | ## Too Bad! 9 | 10 | ![](https://raw.githubusercontent.com/mattn/go-colorable/gh-pages/bad.png) 11 | 12 | 13 | ## So Good! 14 | 15 | ![](https://raw.githubusercontent.com/mattn/go-colorable/gh-pages/good.png) 16 | 17 | ## Usage 18 | 19 | ```go 20 | logrus.SetFormatter(&logrus.TextFormatter{ForceColors: true}) 21 | logrus.SetOutput(colorable.NewColorableStdout()) 22 | 23 | logrus.Info("succeeded") 24 | logrus.Warn("not correct") 25 | logrus.Error("something error") 26 | logrus.Fatal("panic") 27 | ``` 28 | 29 | You can compile above code on non-windows OSs. 30 | 31 | ## Installation 32 | 33 | ``` 34 | $ go get github.com/mattn/go-colorable 35 | ``` 36 | 37 | # License 38 | 39 | MIT 40 | 41 | # Author 42 | 43 | Yasuhiro Matsumoto (a.k.a mattn) 44 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-colorable/colorable_others.go: -------------------------------------------------------------------------------- 1 | // +build !windows 2 | 3 | package colorable 4 | 5 | import ( 6 | "io" 7 | "os" 8 | ) 9 | 10 | func NewColorable(file *os.File) io.Writer { 11 | if file == nil { 12 | panic("nil passed instead of *os.File to NewColorable()") 13 | } 14 | 15 | return file 16 | } 17 | 18 | func NewColorableStdout() io.Writer { 19 | return os.Stdout 20 | } 21 | 22 | func NewColorableStderr() io.Writer { 23 | return os.Stderr 24 | } 25 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/README.md: -------------------------------------------------------------------------------- 1 | # go-isatty 2 | 3 | isatty for golang 4 | 5 | ## Usage 6 | 7 | ```go 8 | package main 9 | 10 | import ( 11 | "fmt" 12 | "github.com/mattn/go-isatty" 13 | "os" 14 | ) 15 | 16 | func main() { 17 | if isatty.IsTerminal(os.Stdout.Fd()) { 18 | fmt.Println("Is Terminal") 19 | } else { 20 | fmt.Println("Is Not Terminal") 21 | } 22 | } 23 | ``` 24 | 25 | ## Installation 26 | 27 | ``` 28 | $ go get github.com/mattn/go-isatty 29 | ``` 30 | 31 | # License 32 | 33 | MIT 34 | 35 | # Author 36 | 37 | Yasuhiro Matsumoto (a.k.a mattn) 38 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/doc.go: -------------------------------------------------------------------------------- 1 | // Package isatty implements interface to isatty 2 | package isatty 3 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/isatty_appengine.go: -------------------------------------------------------------------------------- 1 | // +build appengine 2 | 3 | package isatty 4 | 5 | // IsTerminal returns true if the file descriptor is terminal which 6 | // is always false on on appengine classic which is a sandboxed PaaS. 7 | func IsTerminal(fd uintptr) bool { 8 | return false 9 | } 10 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/isatty_bsd.go: -------------------------------------------------------------------------------- 1 | // +build darwin freebsd openbsd netbsd 2 | // +build !appengine 3 | 4 | package isatty 5 | 6 | import ( 7 | "syscall" 8 | "unsafe" 9 | ) 10 | 11 | const ioctlReadTermios = syscall.TIOCGETA 12 | 13 | // IsTerminal return true if the file descriptor is terminal. 14 | func IsTerminal(fd uintptr) bool { 15 | var termios syscall.Termios 16 | _, _, err := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&termios)), 0, 0, 0) 17 | return err == 0 18 | } 19 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/isatty_linux.go: -------------------------------------------------------------------------------- 1 | // +build linux 2 | // +build !appengine 3 | 4 | package isatty 5 | 6 | import ( 7 | "syscall" 8 | "unsafe" 9 | ) 10 | 11 | const ioctlReadTermios = syscall.TCGETS 12 | 13 | // IsTerminal return true if the file descriptor is terminal. 14 | func IsTerminal(fd uintptr) bool { 15 | var termios syscall.Termios 16 | _, _, err := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&termios)), 0, 0, 0) 17 | return err == 0 18 | } 19 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/isatty_solaris.go: -------------------------------------------------------------------------------- 1 | // +build solaris 2 | // +build !appengine 3 | 4 | package isatty 5 | 6 | import ( 7 | "golang.org/x/sys/unix" 8 | ) 9 | 10 | // IsTerminal returns true if the given file descriptor is a terminal. 11 | // see: http://src.illumos.org/source/xref/illumos-gate/usr/src/lib/libbc/libc/gen/common/isatty.c 12 | func IsTerminal(fd uintptr) bool { 13 | var termio unix.Termio 14 | err := unix.IoctlSetTermio(int(fd), unix.TCGETA, &termio) 15 | return err == nil 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/reporters/stenographer/support/go-isatty/isatty_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | // +build !appengine 3 | 4 | package isatty 5 | 6 | import ( 7 | "syscall" 8 | "unsafe" 9 | ) 10 | 11 | var kernel32 = syscall.NewLazyDLL("kernel32.dll") 12 | var procGetConsoleMode = kernel32.NewProc("GetConsoleMode") 13 | 14 | // IsTerminal return true if the file descriptor is terminal. 15 | func IsTerminal(fd uintptr) bool { 16 | var st uint32 17 | r, _, e := syscall.Syscall(procGetConsoleMode.Addr(), 2, fd, uintptr(unsafe.Pointer(&st)), 0) 18 | return r != 0 && e == 0 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/types/code_location.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | import ( 4 | "fmt" 5 | ) 6 | 7 | type CodeLocation struct { 8 | FileName string 9 | LineNumber int 10 | FullStackTrace string 11 | } 12 | 13 | func (codeLocation CodeLocation) String() string { 14 | return fmt.Sprintf("%s:%d", codeLocation.FileName, codeLocation.LineNumber) 15 | } 16 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/ginkgo/types/synchronization.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | import ( 4 | "encoding/json" 5 | ) 6 | 7 | type RemoteBeforeSuiteState int 8 | 9 | const ( 10 | RemoteBeforeSuiteStateInvalid RemoteBeforeSuiteState = iota 11 | 12 | RemoteBeforeSuiteStatePending 13 | RemoteBeforeSuiteStatePassed 14 | RemoteBeforeSuiteStateFailed 15 | RemoteBeforeSuiteStateDisappeared 16 | ) 17 | 18 | type RemoteBeforeSuiteData struct { 19 | Data []byte 20 | State RemoteBeforeSuiteState 21 | } 22 | 23 | func (r RemoteBeforeSuiteData) ToJSON() []byte { 24 | data, _ := json.Marshal(r) 25 | return data 26 | } 27 | 28 | type RemoteAfterSuiteData struct { 29 | CanRun bool 30 | } 31 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | *.test 3 | . 4 | .idea 5 | gomega.iml 6 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | arch: 3 | - amd64 4 | - ppc64le 5 | 6 | go: 7 | - gotip 8 | - 1.16.x 9 | - 1.15.x 10 | 11 | env: 12 | - GO111MODULE=on 13 | 14 | install: skip 15 | 16 | script: 17 | - go mod tidy && git diff --exit-code go.mod go.sum 18 | - make test 19 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing to Gomega 2 | 3 | Your contributions to Gomega are essential for its long-term maintenance and improvement. To make a contribution: 4 | 5 | - Please **open an issue first** - describe what problem you are trying to solve and give the community a forum for input and feedback ahead of investing time in writing code! 6 | - Ensure adequate test coverage: 7 | - Make sure to add appropriate unit tests 8 | - Please run all tests locally (`ginkgo -r -p`) and make sure they go green before submitting the PR 9 | - Please run following linter locally `go vet ./...` and make sure output does not contain any warnings 10 | - Update the documentation. In addition to standard `godoc` comments Gomega has extensive documentation on the `gh-pages` branch. If relevant, please submit a docs PR to that branch alongside your code PR. 11 | 12 | If you're a committer, check out RELEASING.md to learn how to cut a release. 13 | 14 | Thanks for supporting Gomega! 15 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM golang:1.15 2 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/README.md: -------------------------------------------------------------------------------- 1 | ![Gomega: Ginkgo's Preferred Matcher Library](http://onsi.github.io/gomega/images/gomega.png) 2 | 3 | [![test](https://github.com/onsi/gomega/actions/workflows/test.yml/badge.svg)](https://github.com/onsi/gomega/actions/workflows/test.yml) 4 | 5 | Jump straight to the [docs](http://onsi.github.io/gomega/) to learn about Gomega, including a list of [all available matchers](http://onsi.github.io/gomega/#provided-matchers). 6 | 7 | If you have a question, comment, bug report, feature request, etc. please open a GitHub issue. 8 | 9 | ## [Ginkgo](http://github.com/onsi/ginkgo): a BDD Testing Framework for Golang 10 | 11 | Learn more about Ginkgo [here](http://onsi.github.io/ginkgo/) 12 | 13 | ## Community Matchers 14 | 15 | A collection of community matchers is available on the [wiki](https://github.com/onsi/gomega/wiki). 16 | 17 | ## License 18 | 19 | Gomega is MIT-Licensed 20 | 21 | The `ConsistOf` matcher uses [goraph](https://github.com/amitkgupta/goraph) which is embedded in the source to simplify distribution. goraph has an MIT license. 22 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/RELEASING.md: -------------------------------------------------------------------------------- 1 | A Gomega release is a tagged sha and a GitHub release. To cut a release: 2 | 3 | 1. Ensure CHANGELOG.md is up to date. 4 | - Use `git log --pretty=format:'- %s [%h]' HEAD...vX.X.X` to list all the commits since the last release 5 | - Categorize the changes into 6 | - Breaking Changes (requires a major version) 7 | - New Features (minor version) 8 | - Fixes (fix version) 9 | - Maintenance (which in general should not be mentioned in `CHANGELOG.md` as they have no user impact) 10 | 2. Update GOMEGA_VERSION in `gomega_dsl.go` 11 | 3. Push a commit with the version number as the commit message (e.g. `v1.3.0`) 12 | 4. Create a new [GitHub release](https://help.github.com/articles/creating-releases/) with the version number as the tag (e.g. `v1.3.0`). List the key changes in the release notes. 13 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/docker-compose.yaml: -------------------------------------------------------------------------------- 1 | version: '3.0' 2 | 3 | services: 4 | test: 5 | build: 6 | dockerfile: Dockerfile 7 | context: . 8 | working_dir: /app 9 | volumes: 10 | - ${PWD}:/app 11 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/go.mod: -------------------------------------------------------------------------------- 1 | module github.com/onsi/gomega 2 | 3 | go 1.16 4 | 5 | require ( 6 | github.com/golang/protobuf v1.5.2 7 | github.com/onsi/ginkgo v1.16.4 8 | golang.org/x/net v0.0.0-20210428140749-89ef3d95e781 9 | gopkg.in/yaml.v2 v2.4.0 10 | ) 11 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/attributes_slice.go: -------------------------------------------------------------------------------- 1 | package matchers 2 | 3 | import ( 4 | "encoding/xml" 5 | "strings" 6 | ) 7 | 8 | type attributesSlice []xml.Attr 9 | 10 | func (attrs attributesSlice) Len() int { return len(attrs) } 11 | func (attrs attributesSlice) Less(i, j int) bool { 12 | return strings.Compare(attrs[i].Name.Local, attrs[j].Name.Local) == -1 13 | } 14 | func (attrs attributesSlice) Swap(i, j int) { attrs[i], attrs[j] = attrs[j], attrs[i] } 15 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/be_an_existing_file.go: -------------------------------------------------------------------------------- 1 | // untested sections: 3 2 | 3 | package matchers 4 | 5 | import ( 6 | "fmt" 7 | "os" 8 | 9 | "github.com/onsi/gomega/format" 10 | ) 11 | 12 | type BeAnExistingFileMatcher struct { 13 | expected interface{} 14 | } 15 | 16 | func (matcher *BeAnExistingFileMatcher) Match(actual interface{}) (success bool, err error) { 17 | actualFilename, ok := actual.(string) 18 | if !ok { 19 | return false, fmt.Errorf("BeAnExistingFileMatcher matcher expects a file path") 20 | } 21 | 22 | if _, err = os.Stat(actualFilename); err != nil { 23 | switch { 24 | case os.IsNotExist(err): 25 | return false, nil 26 | default: 27 | return false, err 28 | } 29 | } 30 | 31 | return true, nil 32 | } 33 | 34 | func (matcher *BeAnExistingFileMatcher) FailureMessage(actual interface{}) (message string) { 35 | return format.Message(actual, fmt.Sprintf("to exist")) 36 | } 37 | 38 | func (matcher *BeAnExistingFileMatcher) NegatedFailureMessage(actual interface{}) (message string) { 39 | return format.Message(actual, fmt.Sprintf("not to exist")) 40 | } 41 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/be_empty_matcher.go: -------------------------------------------------------------------------------- 1 | // untested sections: 2 2 | 3 | package matchers 4 | 5 | import ( 6 | "fmt" 7 | 8 | "github.com/onsi/gomega/format" 9 | ) 10 | 11 | type BeEmptyMatcher struct { 12 | } 13 | 14 | func (matcher *BeEmptyMatcher) Match(actual interface{}) (success bool, err error) { 15 | length, ok := lengthOf(actual) 16 | if !ok { 17 | return false, fmt.Errorf("BeEmpty matcher expects a string/array/map/channel/slice. Got:\n%s", format.Object(actual, 1)) 18 | } 19 | 20 | return length == 0, nil 21 | } 22 | 23 | func (matcher *BeEmptyMatcher) FailureMessage(actual interface{}) (message string) { 24 | return format.Message(actual, "to be empty") 25 | } 26 | 27 | func (matcher *BeEmptyMatcher) NegatedFailureMessage(actual interface{}) (message string) { 28 | return format.Message(actual, "not to be empty") 29 | } 30 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/be_false_matcher.go: -------------------------------------------------------------------------------- 1 | // untested sections: 2 2 | 3 | package matchers 4 | 5 | import ( 6 | "fmt" 7 | 8 | "github.com/onsi/gomega/format" 9 | ) 10 | 11 | type BeFalseMatcher struct { 12 | } 13 | 14 | func (matcher *BeFalseMatcher) Match(actual interface{}) (success bool, err error) { 15 | if !isBool(actual) { 16 | return false, fmt.Errorf("Expected a boolean. Got:\n%s", format.Object(actual, 1)) 17 | } 18 | 19 | return actual == false, nil 20 | } 21 | 22 | func (matcher *BeFalseMatcher) FailureMessage(actual interface{}) (message string) { 23 | return format.Message(actual, "to be false") 24 | } 25 | 26 | func (matcher *BeFalseMatcher) NegatedFailureMessage(actual interface{}) (message string) { 27 | return format.Message(actual, "not to be false") 28 | } 29 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/be_nil_matcher.go: -------------------------------------------------------------------------------- 1 | // untested sections: 2 2 | 3 | package matchers 4 | 5 | import "github.com/onsi/gomega/format" 6 | 7 | type BeNilMatcher struct { 8 | } 9 | 10 | func (matcher *BeNilMatcher) Match(actual interface{}) (success bool, err error) { 11 | return isNil(actual), nil 12 | } 13 | 14 | func (matcher *BeNilMatcher) FailureMessage(actual interface{}) (message string) { 15 | return format.Message(actual, "to be nil") 16 | } 17 | 18 | func (matcher *BeNilMatcher) NegatedFailureMessage(actual interface{}) (message string) { 19 | return format.Message(actual, "not to be nil") 20 | } 21 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/be_true_matcher.go: -------------------------------------------------------------------------------- 1 | // untested sections: 2 2 | 3 | package matchers 4 | 5 | import ( 6 | "fmt" 7 | 8 | "github.com/onsi/gomega/format" 9 | ) 10 | 11 | type BeTrueMatcher struct { 12 | } 13 | 14 | func (matcher *BeTrueMatcher) Match(actual interface{}) (success bool, err error) { 15 | if !isBool(actual) { 16 | return false, fmt.Errorf("Expected a boolean. Got:\n%s", format.Object(actual, 1)) 17 | } 18 | 19 | return actual.(bool), nil 20 | } 21 | 22 | func (matcher *BeTrueMatcher) FailureMessage(actual interface{}) (message string) { 23 | return format.Message(actual, "to be true") 24 | } 25 | 26 | func (matcher *BeTrueMatcher) NegatedFailureMessage(actual interface{}) (message string) { 27 | return format.Message(actual, "not to be true") 28 | } 29 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/be_zero_matcher.go: -------------------------------------------------------------------------------- 1 | package matchers 2 | 3 | import ( 4 | "reflect" 5 | 6 | "github.com/onsi/gomega/format" 7 | ) 8 | 9 | type BeZeroMatcher struct { 10 | } 11 | 12 | func (matcher *BeZeroMatcher) Match(actual interface{}) (success bool, err error) { 13 | if actual == nil { 14 | return true, nil 15 | } 16 | zeroValue := reflect.Zero(reflect.TypeOf(actual)).Interface() 17 | 18 | return reflect.DeepEqual(zeroValue, actual), nil 19 | 20 | } 21 | 22 | func (matcher *BeZeroMatcher) FailureMessage(actual interface{}) (message string) { 23 | return format.Message(actual, "to be zero-valued") 24 | } 25 | 26 | func (matcher *BeZeroMatcher) NegatedFailureMessage(actual interface{}) (message string) { 27 | return format.Message(actual, "not to be zero-valued") 28 | } 29 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/have_cap_matcher.go: -------------------------------------------------------------------------------- 1 | // untested sections: 2 2 | 3 | package matchers 4 | 5 | import ( 6 | "fmt" 7 | 8 | "github.com/onsi/gomega/format" 9 | ) 10 | 11 | type HaveCapMatcher struct { 12 | Count int 13 | } 14 | 15 | func (matcher *HaveCapMatcher) Match(actual interface{}) (success bool, err error) { 16 | length, ok := capOf(actual) 17 | if !ok { 18 | return false, fmt.Errorf("HaveCap matcher expects a array/channel/slice. Got:\n%s", format.Object(actual, 1)) 19 | } 20 | 21 | return length == matcher.Count, nil 22 | } 23 | 24 | func (matcher *HaveCapMatcher) FailureMessage(actual interface{}) (message string) { 25 | return fmt.Sprintf("Expected\n%s\nto have capacity %d", format.Object(actual, 1), matcher.Count) 26 | } 27 | 28 | func (matcher *HaveCapMatcher) NegatedFailureMessage(actual interface{}) (message string) { 29 | return fmt.Sprintf("Expected\n%s\nnot to have capacity %d", format.Object(actual, 1), matcher.Count) 30 | } 31 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/have_len_matcher.go: -------------------------------------------------------------------------------- 1 | package matchers 2 | 3 | import ( 4 | "fmt" 5 | 6 | "github.com/onsi/gomega/format" 7 | ) 8 | 9 | type HaveLenMatcher struct { 10 | Count int 11 | } 12 | 13 | func (matcher *HaveLenMatcher) Match(actual interface{}) (success bool, err error) { 14 | length, ok := lengthOf(actual) 15 | if !ok { 16 | return false, fmt.Errorf("HaveLen matcher expects a string/array/map/channel/slice. Got:\n%s", format.Object(actual, 1)) 17 | } 18 | 19 | return length == matcher.Count, nil 20 | } 21 | 22 | func (matcher *HaveLenMatcher) FailureMessage(actual interface{}) (message string) { 23 | return fmt.Sprintf("Expected\n%s\nto have length %d", format.Object(actual, 1), matcher.Count) 24 | } 25 | 26 | func (matcher *HaveLenMatcher) NegatedFailureMessage(actual interface{}) (message string) { 27 | return fmt.Sprintf("Expected\n%s\nnot to have length %d", format.Object(actual, 1), matcher.Count) 28 | } 29 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/have_occurred_matcher.go: -------------------------------------------------------------------------------- 1 | // untested sections: 2 2 | 3 | package matchers 4 | 5 | import ( 6 | "fmt" 7 | 8 | "github.com/onsi/gomega/format" 9 | ) 10 | 11 | type HaveOccurredMatcher struct { 12 | } 13 | 14 | func (matcher *HaveOccurredMatcher) Match(actual interface{}) (success bool, err error) { 15 | // is purely nil? 16 | if actual == nil { 17 | return false, nil 18 | } 19 | 20 | // must be an 'error' type 21 | if !isError(actual) { 22 | return false, fmt.Errorf("Expected an error-type. Got:\n%s", format.Object(actual, 1)) 23 | } 24 | 25 | // must be non-nil (or a pointer to a non-nil) 26 | return !isNil(actual), nil 27 | } 28 | 29 | func (matcher *HaveOccurredMatcher) FailureMessage(actual interface{}) (message string) { 30 | return fmt.Sprintf("Expected an error to have occurred. Got:\n%s", format.Object(actual, 1)) 31 | } 32 | 33 | func (matcher *HaveOccurredMatcher) NegatedFailureMessage(actual interface{}) (message string) { 34 | return fmt.Sprintf("Unexpected error:\n%s\n%s\n%s", format.Object(actual, 1), format.IndentString(actual.(error).Error(), 1), "occurred") 35 | } 36 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/not.go: -------------------------------------------------------------------------------- 1 | package matchers 2 | 3 | import ( 4 | "github.com/onsi/gomega/types" 5 | ) 6 | 7 | type NotMatcher struct { 8 | Matcher types.GomegaMatcher 9 | } 10 | 11 | func (m *NotMatcher) Match(actual interface{}) (bool, error) { 12 | success, err := m.Matcher.Match(actual) 13 | if err != nil { 14 | return false, err 15 | } 16 | return !success, nil 17 | } 18 | 19 | func (m *NotMatcher) FailureMessage(actual interface{}) (message string) { 20 | return m.Matcher.NegatedFailureMessage(actual) // works beautifully 21 | } 22 | 23 | func (m *NotMatcher) NegatedFailureMessage(actual interface{}) (message string) { 24 | return m.Matcher.FailureMessage(actual) // works beautifully 25 | } 26 | 27 | func (m *NotMatcher) MatchMayChangeInTheFuture(actual interface{}) bool { 28 | return types.MatchMayChangeInTheFuture(m.Matcher, actual) // just return m.Matcher's value 29 | } 30 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/succeed_matcher.go: -------------------------------------------------------------------------------- 1 | package matchers 2 | 3 | import ( 4 | "fmt" 5 | 6 | "github.com/onsi/gomega/format" 7 | ) 8 | 9 | type SucceedMatcher struct { 10 | } 11 | 12 | func (matcher *SucceedMatcher) Match(actual interface{}) (success bool, err error) { 13 | // is purely nil? 14 | if actual == nil { 15 | return true, nil 16 | } 17 | 18 | // must be an 'error' type 19 | if !isError(actual) { 20 | return false, fmt.Errorf("Expected an error-type. Got:\n%s", format.Object(actual, 1)) 21 | } 22 | 23 | // must be nil (or a pointer to a nil) 24 | return isNil(actual), nil 25 | } 26 | 27 | func (matcher *SucceedMatcher) FailureMessage(actual interface{}) (message string) { 28 | return fmt.Sprintf("Expected success, but got an error:\n%s\n%s", format.Object(actual, 1), format.IndentString(actual.(error).Error(), 1)) 29 | } 30 | 31 | func (matcher *SucceedMatcher) NegatedFailureMessage(actual interface{}) (message string) { 32 | return "Expected failure, but got no error." 33 | } 34 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/support/goraph/node/node.go: -------------------------------------------------------------------------------- 1 | package node 2 | 3 | type Node struct { 4 | ID int 5 | Value interface{} 6 | } 7 | 8 | type NodeOrderedSet []Node 9 | -------------------------------------------------------------------------------- /vendor/github.com/onsi/gomega/matchers/support/goraph/util/util.go: -------------------------------------------------------------------------------- 1 | package util 2 | 3 | import "math" 4 | 5 | func Odd(n int) bool { 6 | return math.Mod(float64(n), 2.0) == 1.0 7 | } 8 | -------------------------------------------------------------------------------- /vendor/github.com/pivotal-cf-experimental/service-config/.gitignore: -------------------------------------------------------------------------------- 1 | /out/* 2 | tmp/ 3 | **/*.test 4 | -------------------------------------------------------------------------------- /vendor/github.com/pivotal-cf-experimental/service-config/.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: false 2 | 3 | language: go 4 | 5 | go: 6 | - 1.4.2 7 | 8 | install: 9 | - go get -t -v -d ./... 10 | - go install github.com/onsi/ginkgo/ginkgo 11 | 12 | before_script: 13 | - export PATH=$HOME/gopath/bin:$PATH 14 | 15 | script: 16 | - ./bin/test 17 | -------------------------------------------------------------------------------- /vendor/github.com/pivotal-cf-experimental/service-config/config_reader.go: -------------------------------------------------------------------------------- 1 | package service_config 2 | 3 | import ( 4 | "errors" 5 | "fmt" 6 | 7 | "gopkg.in/yaml.v2" 8 | 9 | "github.com/imdario/mergo" 10 | ) 11 | 12 | type Reader struct { 13 | configBytes []byte 14 | } 15 | 16 | func NewReader(configBytes []byte) *Reader { 17 | return &Reader{ 18 | configBytes: configBytes, 19 | } 20 | } 21 | 22 | func (r Reader) Read(model interface{}) error { 23 | err := yaml.Unmarshal(r.configBytes, model) 24 | if err != nil { 25 | return errors.New(fmt.Sprintf("Unmarshaling config: %s", err.Error())) 26 | } 27 | 28 | return nil 29 | } 30 | 31 | func (r Reader) ReadWithDefaults(model interface{}, defaults interface{}) error { 32 | 33 | err := r.Read(model) 34 | if err != nil { 35 | return err 36 | } 37 | 38 | return mergo.Merge(model, defaults) 39 | } 40 | -------------------------------------------------------------------------------- /vendor/github.com/tedsuo/ifrit/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | 3 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 4 | *.o 5 | *.a 6 | *.so 7 | 8 | # Folders 9 | _obj 10 | _test 11 | 12 | *.exe 13 | 14 | *.iml 15 | *.zpi 16 | *.zwi 17 | 18 | *.go-e 19 | 20 | # Test output 21 | *.test 22 | 23 | # Log files 24 | *.log 25 | 26 | # IDE 27 | .idea/ 28 | 29 | -------------------------------------------------------------------------------- /vendor/github.com/tedsuo/ifrit/ginkgomon/helpers.go: -------------------------------------------------------------------------------- 1 | package ginkgomon 2 | 3 | import ( 4 | "fmt" 5 | "os" 6 | 7 | "github.com/onsi/ginkgo" 8 | . "github.com/onsi/gomega" 9 | "github.com/tedsuo/ifrit" 10 | ) 11 | 12 | func Invoke(runner ifrit.Runner) ifrit.Process { 13 | process := ifrit.Background(runner) 14 | 15 | select { 16 | case <-process.Ready(): 17 | case err := <-process.Wait(): 18 | ginkgo.Fail(fmt.Sprintf("process failed to start: %s", err), 1) 19 | } 20 | 21 | return process 22 | } 23 | 24 | func Interrupt(process ifrit.Process, intervals ...interface{}) { 25 | if process != nil { 26 | process.Signal(os.Interrupt) 27 | EventuallyWithOffset(1, process.Wait(), intervals...).Should(Receive(), "interrupted ginkgomon process failed to exit in time") 28 | } 29 | } 30 | 31 | func Kill(process ifrit.Process, intervals ...interface{}) { 32 | if process != nil { 33 | process.Signal(os.Kill) 34 | EventuallyWithOffset(1, process.Wait(), intervals...).Should(Receive(), "killed ginkgomon process failed to exit in time") 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /vendor/github.com/tedsuo/ifrit/grouper/sliding_buffer.go: -------------------------------------------------------------------------------- 1 | package grouper 2 | 3 | import "container/list" 4 | 5 | type slidingBuffer struct { 6 | buffer *list.List 7 | capacity int 8 | } 9 | 10 | func newSlidingBuffer(capacity int) slidingBuffer { 11 | return slidingBuffer{list.New(), capacity} 12 | } 13 | 14 | func (b slidingBuffer) Append(item interface{}) { 15 | if b.capacity == 0 { 16 | return 17 | } 18 | 19 | b.buffer.PushBack(item) 20 | if b.buffer.Len() > b.capacity { 21 | b.buffer.Remove(b.buffer.Front()) 22 | } 23 | } 24 | 25 | func (b slidingBuffer) Range(callback func(item interface{})) { 26 | elem := b.buffer.Front() 27 | for elem != nil { 28 | callback(elem.Value) 29 | elem = elem.Next() 30 | } 31 | } 32 | 33 | func (b slidingBuffer) Length() int { 34 | return b.buffer.Len() 35 | } 36 | -------------------------------------------------------------------------------- /vendor/github.com/tedsuo/ifrit/sigmon/sigmon.go: -------------------------------------------------------------------------------- 1 | package sigmon 2 | 3 | import ( 4 | "os" 5 | "os/signal" 6 | "syscall" 7 | 8 | "github.com/tedsuo/ifrit" 9 | ) 10 | 11 | const SIGNAL_BUFFER_SIZE = 1024 12 | 13 | type sigmon struct { 14 | Signals []os.Signal 15 | Runner ifrit.Runner 16 | } 17 | 18 | func New(runner ifrit.Runner, signals ...os.Signal) ifrit.Runner { 19 | signals = append(signals, syscall.SIGINT, syscall.SIGTERM) 20 | return &sigmon{ 21 | Signals: signals, 22 | Runner: runner, 23 | } 24 | } 25 | 26 | func (s sigmon) Run(signals <-chan os.Signal, ready chan<- struct{}) error { 27 | osSignals := make(chan os.Signal, SIGNAL_BUFFER_SIZE) 28 | signal.Notify(osSignals, s.Signals...) 29 | 30 | process := ifrit.Background(s.Runner) 31 | pReady := process.Ready() 32 | pWait := process.Wait() 33 | 34 | for { 35 | select { 36 | case sig := <-signals: 37 | process.Signal(sig) 38 | case sig := <-osSignals: 39 | process.Signal(sig) 40 | case <-pReady: 41 | close(ready) 42 | pReady = nil 43 | case err := <-pWait: 44 | signal.Stop(osSignals) 45 | return err 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /vendor/github.com/tedsuo/rata/VERSION: -------------------------------------------------------------------------------- 1 | 1.0.0 2 | -------------------------------------------------------------------------------- /vendor/github.com/tedsuo/rata/param.go: -------------------------------------------------------------------------------- 1 | package rata 2 | 3 | import "net/http" 4 | 5 | // Param returns the parameter with the given name from the given request. 6 | func Param(req *http.Request, paramName string) string { 7 | return req.URL.Query().Get(":" + paramName) 8 | } 9 | -------------------------------------------------------------------------------- /vendor/golang.org/x/net/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/net/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/internal/unsafeheader/unsafeheader.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package unsafeheader contains header declarations for the Go runtime's 6 | // slice and string implementations. 7 | // 8 | // This package allows x/sys to use types equivalent to 9 | // reflect.SliceHeader and reflect.StringHeader without introducing 10 | // a dependency on the (relatively heavy) "reflect" package. 11 | package unsafeheader 12 | 13 | import ( 14 | "unsafe" 15 | ) 16 | 17 | // Slice is the runtime representation of a slice. 18 | // It cannot be used safely or portably and its representation may change in a later release. 19 | type Slice struct { 20 | Data unsafe.Pointer 21 | Len int 22 | Cap int 23 | } 24 | 25 | // String is the runtime representation of a string. 26 | // It cannot be used safely or portably and its representation may change in a later release. 27 | type String struct { 28 | Data unsafe.Pointer 29 | Len int 30 | } 31 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/.gitignore: -------------------------------------------------------------------------------- 1 | _obj/ 2 | unix.test 3 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/aliases.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos) && go1.9 6 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris zos 7 | // +build go1.9 8 | 9 | package unix 10 | 11 | import "syscall" 12 | 13 | type Signal = syscall.Signal 14 | type Errno = syscall.Errno 15 | type SysProcAttr = syscall.SysProcAttr 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_aix_ppc64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | // +build gc 7 | 8 | #include "textflag.h" 9 | 10 | // 11 | // System calls for ppc64, AIX are implemented in runtime/syscall_aix.go 12 | // 13 | 14 | TEXT ·syscall6(SB),NOSPLIT,$0-88 15 | JMP syscall·syscall6(SB) 16 | 17 | TEXT ·rawSyscall6(SB),NOSPLIT,$0-88 18 | JMP syscall·rawSyscall6(SB) 19 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (freebsd || netbsd || openbsd) && gc 6 | // +build freebsd netbsd openbsd 7 | // +build gc 8 | 9 | #include "textflag.h" 10 | 11 | // System call support for 386 BSD 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && gc 6 | // +build darwin dragonfly freebsd netbsd openbsd 7 | // +build gc 8 | 9 | #include "textflag.h" 10 | 11 | // System call support for AMD64 BSD 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_arm.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (freebsd || netbsd || openbsd) && gc 6 | // +build freebsd netbsd openbsd 7 | // +build gc 8 | 9 | #include "textflag.h" 10 | 11 | // System call support for ARM BSD 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-28 17 | B syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 20 | B syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 23 | B syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 26 | B syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 29 | B syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_arm64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || freebsd || netbsd || openbsd) && gc 6 | // +build darwin freebsd netbsd openbsd 7 | // +build gc 8 | 9 | #include "textflag.h" 10 | 11 | // System call support for ARM64 BSD 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_openbsd_mips64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | // +build gc 7 | 8 | #include "textflag.h" 9 | 10 | // 11 | // System call support for mips64, OpenBSD 12 | // 13 | 14 | // Just jump to package syscall's implementation for all these functions. 15 | // The runtime may know about them. 16 | 17 | TEXT ·Syscall(SB),NOSPLIT,$0-56 18 | JMP syscall·Syscall(SB) 19 | 20 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 21 | JMP syscall·Syscall6(SB) 22 | 23 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 24 | JMP syscall·Syscall9(SB) 25 | 26 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 27 | JMP syscall·RawSyscall(SB) 28 | 29 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 30 | JMP syscall·RawSyscall6(SB) 31 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_solaris_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | // +build gc 7 | 8 | #include "textflag.h" 9 | 10 | // 11 | // System calls for amd64, Solaris are implemented in runtime/syscall_solaris.go 12 | // 13 | 14 | TEXT ·sysvicall6(SB),NOSPLIT,$0-88 15 | JMP syscall·sysvicall6(SB) 16 | 17 | TEXT ·rawSysvicall6(SB),NOSPLIT,$0-88 18 | JMP syscall·rawSysvicall6(SB) 19 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/bluetooth_linux.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Bluetooth sockets and messages 6 | 7 | package unix 8 | 9 | // Bluetooth Protocols 10 | const ( 11 | BTPROTO_L2CAP = 0 12 | BTPROTO_HCI = 1 13 | BTPROTO_SCO = 2 14 | BTPROTO_RFCOMM = 3 15 | BTPROTO_BNEP = 4 16 | BTPROTO_CMTP = 5 17 | BTPROTO_HIDP = 6 18 | BTPROTO_AVDTP = 7 19 | ) 20 | 21 | const ( 22 | HCI_CHANNEL_RAW = 0 23 | HCI_CHANNEL_USER = 1 24 | HCI_CHANNEL_MONITOR = 2 25 | HCI_CHANNEL_CONTROL = 3 26 | HCI_CHANNEL_LOGGING = 4 27 | ) 28 | 29 | // Socketoption Level 30 | const ( 31 | SOL_BLUETOOTH = 0x112 32 | SOL_HCI = 0x0 33 | SOL_L2CAP = 0x6 34 | SOL_RFCOMM = 0x12 35 | SOL_SCO = 0x11 36 | ) 37 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/constants.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris zos 7 | 8 | package unix 9 | 10 | const ( 11 | R_OK = 0x4 12 | W_OK = 0x2 13 | X_OK = 0x1 14 | ) 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/dev_aix_ppc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix && ppc 6 | // +build aix,ppc 7 | 8 | // Functions to access/create device major and minor numbers matching the 9 | // encoding used by AIX. 10 | 11 | package unix 12 | 13 | // Major returns the major component of a Linux device number. 14 | func Major(dev uint64) uint32 { 15 | return uint32((dev >> 16) & 0xffff) 16 | } 17 | 18 | // Minor returns the minor component of a Linux device number. 19 | func Minor(dev uint64) uint32 { 20 | return uint32(dev & 0xffff) 21 | } 22 | 23 | // Mkdev returns a Linux device number generated from the given major and minor 24 | // components. 25 | func Mkdev(major, minor uint32) uint64 { 26 | return uint64(((major) << 16) | (minor)) 27 | } 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/dev_aix_ppc64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix && ppc64 6 | // +build aix,ppc64 7 | 8 | // Functions to access/create device major and minor numbers matching the 9 | // encoding used AIX. 10 | 11 | package unix 12 | 13 | // Major returns the major component of a Linux device number. 14 | func Major(dev uint64) uint32 { 15 | return uint32((dev & 0x3fffffff00000000) >> 32) 16 | } 17 | 18 | // Minor returns the minor component of a Linux device number. 19 | func Minor(dev uint64) uint32 { 20 | return uint32((dev & 0x00000000ffffffff) >> 0) 21 | } 22 | 23 | // Mkdev returns a Linux device number generated from the given major and minor 24 | // components. 25 | func Mkdev(major, minor uint32) uint64 { 26 | var DEVNO64 uint64 27 | DEVNO64 = 0x8000000000000000 28 | return ((uint64(major) << 32) | (uint64(minor) & 0x00000000FFFFFFFF) | DEVNO64) 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/dev_darwin.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Functions to access/create device major and minor numbers matching the 6 | // encoding used in Darwin's sys/types.h header. 7 | 8 | package unix 9 | 10 | // Major returns the major component of a Darwin device number. 11 | func Major(dev uint64) uint32 { 12 | return uint32((dev >> 24) & 0xff) 13 | } 14 | 15 | // Minor returns the minor component of a Darwin device number. 16 | func Minor(dev uint64) uint32 { 17 | return uint32(dev & 0xffffff) 18 | } 19 | 20 | // Mkdev returns a Darwin device number generated from the given major and minor 21 | // components. 22 | func Mkdev(major, minor uint32) uint64 { 23 | return (uint64(major) << 24) | uint64(minor) 24 | } 25 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/dev_netbsd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Functions to access/create device major and minor numbers matching the 6 | // encoding used in NetBSD's sys/types.h header. 7 | 8 | package unix 9 | 10 | // Major returns the major component of a NetBSD device number. 11 | func Major(dev uint64) uint32 { 12 | return uint32((dev & 0x000fff00) >> 8) 13 | } 14 | 15 | // Minor returns the minor component of a NetBSD device number. 16 | func Minor(dev uint64) uint32 { 17 | minor := uint32((dev & 0x000000ff) >> 0) 18 | minor |= uint32((dev & 0xfff00000) >> 12) 19 | return minor 20 | } 21 | 22 | // Mkdev returns a NetBSD device number generated from the given major and minor 23 | // components. 24 | func Mkdev(major, minor uint32) uint64 { 25 | dev := (uint64(major) << 8) & 0x000fff00 26 | dev |= (uint64(minor) << 12) & 0xfff00000 27 | dev |= (uint64(minor) << 0) & 0x000000ff 28 | return dev 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/dev_openbsd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Functions to access/create device major and minor numbers matching the 6 | // encoding used in OpenBSD's sys/types.h header. 7 | 8 | package unix 9 | 10 | // Major returns the major component of an OpenBSD device number. 11 | func Major(dev uint64) uint32 { 12 | return uint32((dev & 0x0000ff00) >> 8) 13 | } 14 | 15 | // Minor returns the minor component of an OpenBSD device number. 16 | func Minor(dev uint64) uint32 { 17 | minor := uint32((dev & 0x000000ff) >> 0) 18 | minor |= uint32((dev & 0xffff0000) >> 8) 19 | return minor 20 | } 21 | 22 | // Mkdev returns an OpenBSD device number generated from the given major and minor 23 | // components. 24 | func Mkdev(major, minor uint32) uint64 { 25 | dev := (uint64(major) << 8) & 0x0000ff00 26 | dev |= (uint64(minor) << 8) & 0xffff0000 27 | dev |= (uint64(minor) << 0) & 0x000000ff 28 | return dev 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/dev_zos.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build zos && s390x 6 | // +build zos,s390x 7 | 8 | // Functions to access/create device major and minor numbers matching the 9 | // encoding used by z/OS. 10 | // 11 | // The information below is extracted and adapted from macros. 12 | 13 | package unix 14 | 15 | // Major returns the major component of a z/OS device number. 16 | func Major(dev uint64) uint32 { 17 | return uint32((dev >> 16) & 0x0000FFFF) 18 | } 19 | 20 | // Minor returns the minor component of a z/OS device number. 21 | func Minor(dev uint64) uint32 { 22 | return uint32(dev & 0x0000FFFF) 23 | } 24 | 25 | // Mkdev returns a z/OS device number generated from the given major and minor 26 | // components. 27 | func Mkdev(major, minor uint32) uint64 { 28 | return (uint64(major) << 16) | uint64(minor) 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/endian_big.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | // 5 | //go:build armbe || arm64be || m68k || mips || mips64 || mips64p32 || ppc || ppc64 || s390 || s390x || shbe || sparc || sparc64 6 | // +build armbe arm64be m68k mips mips64 mips64p32 ppc ppc64 s390 s390x shbe sparc sparc64 7 | 8 | package unix 9 | 10 | const isBigEndian = true 11 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/endian_little.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | // 5 | //go:build 386 || amd64 || amd64p32 || alpha || arm || arm64 || mipsle || mips64le || mips64p32le || nios2 || ppc64le || riscv || riscv64 || sh 6 | // +build 386 amd64 amd64p32 alpha arm arm64 mipsle mips64le mips64p32le nios2 ppc64le riscv riscv64 sh 7 | 8 | package unix 9 | 10 | const isBigEndian = false 11 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/env_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2010 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris zos 7 | 8 | // Unix environment variables. 9 | 10 | package unix 11 | 12 | import "syscall" 13 | 14 | func Getenv(key string) (value string, found bool) { 15 | return syscall.Getenv(key) 16 | } 17 | 18 | func Setenv(key, value string) error { 19 | return syscall.Setenv(key, value) 20 | } 21 | 22 | func Clearenv() { 23 | syscall.Clearenv() 24 | } 25 | 26 | func Environ() []string { 27 | return syscall.Environ() 28 | } 29 | 30 | func Unsetenv(key string) error { 31 | return syscall.Unsetenv(key) 32 | } 33 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/errors_freebsd_arm64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Constants that were deprecated or moved to enums in the FreeBSD headers. Keep 6 | // them here for backwards compatibility. 7 | 8 | package unix 9 | 10 | const ( 11 | DLT_HHDLC = 0x79 12 | IPV6_MIN_MEMBERSHIPS = 0x1f 13 | IP_MAX_SOURCE_FILTER = 0x400 14 | IP_MIN_MEMBERSHIPS = 0x1f 15 | RT_CACHING_CONTEXT = 0x1 16 | RT_NORTREF = 0x2 17 | ) 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/fcntl_darwin.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package unix 6 | 7 | import "unsafe" 8 | 9 | // FcntlInt performs a fcntl syscall on fd with the provided command and argument. 10 | func FcntlInt(fd uintptr, cmd, arg int) (int, error) { 11 | return fcntl(int(fd), cmd, arg) 12 | } 13 | 14 | // FcntlFlock performs a fcntl syscall for the F_GETLK, F_SETLK or F_SETLKW command. 15 | func FcntlFlock(fd uintptr, cmd int, lk *Flock_t) error { 16 | _, err := fcntl(int(fd), cmd, int(uintptr(unsafe.Pointer(lk)))) 17 | return err 18 | } 19 | 20 | // FcntlFstore performs a fcntl syscall for the F_PREALLOCATE command. 21 | func FcntlFstore(fd uintptr, cmd int, fstore *Fstore_t) error { 22 | _, err := fcntl(int(fd), cmd, int(uintptr(unsafe.Pointer(fstore)))) 23 | return err 24 | } 25 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/fcntl_linux_32bit.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (linux && 386) || (linux && arm) || (linux && mips) || (linux && mipsle) || (linux && ppc) 6 | // +build linux,386 linux,arm linux,mips linux,mipsle linux,ppc 7 | 8 | package unix 9 | 10 | func init() { 11 | // On 32-bit Linux systems, the fcntl syscall that matches Go's 12 | // Flock_t type is SYS_FCNTL64, not SYS_FCNTL. 13 | fcntl64Syscall = SYS_FCNTL64 14 | } 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/fdset.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris zos 7 | 8 | package unix 9 | 10 | // Set adds fd to the set fds. 11 | func (fds *FdSet) Set(fd int) { 12 | fds.Bits[fd/NFDBITS] |= (1 << (uintptr(fd) % NFDBITS)) 13 | } 14 | 15 | // Clear removes fd from the set fds. 16 | func (fds *FdSet) Clear(fd int) { 17 | fds.Bits[fd/NFDBITS] &^= (1 << (uintptr(fd) % NFDBITS)) 18 | } 19 | 20 | // IsSet returns whether fd is in the set fds. 21 | func (fds *FdSet) IsSet(fd int) bool { 22 | return fds.Bits[fd/NFDBITS]&(1<<(uintptr(fd)%NFDBITS)) != 0 23 | } 24 | 25 | // Zero clears the set fds. 26 | func (fds *FdSet) Zero() { 27 | for i := range fds.Bits { 28 | fds.Bits[i] = 0 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/gccgo_linux_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gccgo && linux && amd64 6 | // +build gccgo,linux,amd64 7 | 8 | package unix 9 | 10 | import "syscall" 11 | 12 | //extern gettimeofday 13 | func realGettimeofday(*Timeval, *byte) int32 14 | 15 | func gettimeofday(tv *Timeval) (err syscall.Errno) { 16 | r := realGettimeofday(tv, nil) 17 | if r < 0 { 18 | return syscall.GetErrno() 19 | } 20 | return 0 21 | } 22 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/pagesize_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris 6 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris 7 | 8 | // For Unix, get the pagesize from the runtime. 9 | 10 | package unix 11 | 12 | import "syscall" 13 | 14 | func Getpagesize() int { 15 | return syscall.Getpagesize() 16 | } 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/ptrace_darwin.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build darwin && !ios 6 | // +build darwin,!ios 7 | 8 | package unix 9 | 10 | func ptrace(request int, pid int, addr uintptr, data uintptr) error { 11 | return ptrace1(request, pid, addr, data) 12 | } 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/ptrace_ios.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build ios 6 | // +build ios 7 | 8 | package unix 9 | 10 | func ptrace(request int, pid int, addr uintptr, data uintptr) (err error) { 11 | return ENOTSUP 12 | } 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/race.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin && race) || (linux && race) || (freebsd && race) 6 | // +build darwin,race linux,race freebsd,race 7 | 8 | package unix 9 | 10 | import ( 11 | "runtime" 12 | "unsafe" 13 | ) 14 | 15 | const raceenabled = true 16 | 17 | func raceAcquire(addr unsafe.Pointer) { 18 | runtime.RaceAcquire(addr) 19 | } 20 | 21 | func raceReleaseMerge(addr unsafe.Pointer) { 22 | runtime.RaceReleaseMerge(addr) 23 | } 24 | 25 | func raceReadRange(addr unsafe.Pointer, len int) { 26 | runtime.RaceReadRange(addr, len) 27 | } 28 | 29 | func raceWriteRange(addr unsafe.Pointer, len int) { 30 | runtime.RaceWriteRange(addr, len) 31 | } 32 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/race0.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || (darwin && !race) || (linux && !race) || (freebsd && !race) || netbsd || openbsd || solaris || dragonfly || zos 6 | // +build aix darwin,!race linux,!race freebsd,!race netbsd openbsd solaris dragonfly zos 7 | 8 | package unix 9 | 10 | import ( 11 | "unsafe" 12 | ) 13 | 14 | const raceenabled = false 15 | 16 | func raceAcquire(addr unsafe.Pointer) { 17 | } 18 | 19 | func raceReleaseMerge(addr unsafe.Pointer) { 20 | } 21 | 22 | func raceReadRange(addr unsafe.Pointer, len int) { 23 | } 24 | 25 | func raceWriteRange(addr unsafe.Pointer, len int) { 26 | } 27 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/readdirent_getdents.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || dragonfly || freebsd || linux || netbsd || openbsd 6 | // +build aix dragonfly freebsd linux netbsd openbsd 7 | 8 | package unix 9 | 10 | // ReadDirent reads directory entries from fd and writes them into buf. 11 | func ReadDirent(fd int, buf []byte) (n int, err error) { 12 | return Getdents(fd, buf) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/readdirent_getdirentries.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build darwin 6 | // +build darwin 7 | 8 | package unix 9 | 10 | import "unsafe" 11 | 12 | // ReadDirent reads directory entries from fd and writes them into buf. 13 | func ReadDirent(fd int, buf []byte) (n int, err error) { 14 | // Final argument is (basep *uintptr) and the syscall doesn't take nil. 15 | // 64 bits should be enough. (32 bits isn't even on 386). Since the 16 | // actual system call is getdirentries64, 64 is a good guess. 17 | // TODO(rsc): Can we use a single global basep for all calls? 18 | var base = (*uintptr)(unsafe.Pointer(new(uint64))) 19 | return Getdirentries(fd, buf, base) 20 | } 21 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/sockcmsg_dragonfly.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package unix 6 | 7 | // Round the length of a raw sockaddr up to align it properly. 8 | func cmsgAlignOf(salen int) int { 9 | salign := SizeofPtr 10 | if SizeofPtr == 8 && !supportsABI(_dragonflyABIChangeVersion) { 11 | // 64-bit Dragonfly before the September 2019 ABI changes still requires 12 | // 32-bit aligned access to network subsystem. 13 | salign = 4 14 | } 15 | return (salen + salign - 1) & ^(salign - 1) 16 | } 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/str.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris 6 | // +build aix darwin dragonfly freebsd linux netbsd openbsd solaris 7 | 8 | package unix 9 | 10 | func itoa(val int) string { // do it here rather than with fmt to avoid dependency 11 | if val < 0 { 12 | return "-" + uitoa(uint(-val)) 13 | } 14 | return uitoa(uint(val)) 15 | } 16 | 17 | func uitoa(val uint) string { 18 | var buf [32]byte // big enough for int64 19 | i := len(buf) - 1 20 | for val >= 10 { 21 | buf[i] = byte(val%10 + '0') 22 | i-- 23 | val /= 10 24 | } 25 | buf[i] = byte(val + '0') 26 | return string(buf[i:]) 27 | } 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_darwin.1_12.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build darwin && go1.12 && !go1.13 6 | // +build darwin,go1.12,!go1.13 7 | 8 | package unix 9 | 10 | import ( 11 | "unsafe" 12 | ) 13 | 14 | const _SYS_GETDIRENTRIES64 = 344 15 | 16 | func Getdirentries(fd int, buf []byte, basep *uintptr) (n int, err error) { 17 | // To implement this using libSystem we'd need syscall_syscallPtr for 18 | // fdopendir. However, syscallPtr was only added in Go 1.13, so we fall 19 | // back to raw syscalls for this func on Go 1.12. 20 | var p unsafe.Pointer 21 | if len(buf) > 0 { 22 | p = unsafe.Pointer(&buf[0]) 23 | } else { 24 | p = unsafe.Pointer(&_zero) 25 | } 26 | r0, _, e1 := Syscall6(_SYS_GETDIRENTRIES64, uintptr(fd), uintptr(p), uintptr(len(buf)), uintptr(unsafe.Pointer(basep)), 0, 0) 27 | n = int(r0) 28 | if e1 != 0 { 29 | return n, errnoErr(e1) 30 | } 31 | return n, nil 32 | } 33 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_amd64_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build amd64 && linux && gc 6 | // +build amd64,linux,gc 7 | 8 | package unix 9 | 10 | import "syscall" 11 | 12 | //go:noescape 13 | func gettimeofday(tv *Timeval) (err syscall.Errno) 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && gc 6 | // +build linux,gc 7 | 8 | package unix 9 | 10 | // SyscallNoError may be used instead of Syscall for syscalls that don't fail. 11 | func SyscallNoError(trap, a1, a2, a3 uintptr) (r1, r2 uintptr) 12 | 13 | // RawSyscallNoError may be used instead of RawSyscall for syscalls that don't 14 | // fail. 15 | func RawSyscallNoError(trap, a1, a2, a3 uintptr) (r1, r2 uintptr) 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gc_386.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && gc && 386 6 | // +build linux,gc,386 7 | 8 | package unix 9 | 10 | import "syscall" 11 | 12 | // Underlying system call writes to newoffset via pointer. 13 | // Implemented in assembly to avoid allocation. 14 | func seek(fd int, offset int64, whence int) (newoffset int64, err syscall.Errno) 15 | 16 | func socketcall(call int, a0, a1, a2, a3, a4, a5 uintptr) (n int, err syscall.Errno) 17 | func rawsocketcall(call int, a0, a1, a2, a3, a4, a5 uintptr) (n int, err syscall.Errno) 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gc_arm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build arm && gc && linux 6 | // +build arm,gc,linux 7 | 8 | package unix 9 | 10 | import "syscall" 11 | 12 | // Underlying system call writes to newoffset via pointer. 13 | // Implemented in assembly to avoid allocation. 14 | func seek(fd int, offset int64, whence int) (newoffset int64, err syscall.Errno) 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gccgo_arm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && gccgo && arm 6 | // +build linux,gccgo,arm 7 | 8 | package unix 9 | 10 | import ( 11 | "syscall" 12 | "unsafe" 13 | ) 14 | 15 | func seek(fd int, offset int64, whence int) (int64, syscall.Errno) { 16 | var newoffset int64 17 | offsetLow := uint32(offset & 0xffffffff) 18 | offsetHigh := uint32((offset >> 32) & 0xffffffff) 19 | _, _, err := Syscall6(SYS__LLSEEK, uintptr(fd), uintptr(offsetHigh), uintptr(offsetLow), uintptr(unsafe.Pointer(&newoffset)), uintptr(whence), 0) 20 | return newoffset, err 21 | } 22 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_netbsd_386.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build 386 && netbsd 6 | // +build 386,netbsd 7 | 8 | package unix 9 | 10 | func setTimespec(sec, nsec int64) Timespec { 11 | return Timespec{Sec: sec, Nsec: int32(nsec)} 12 | } 13 | 14 | func setTimeval(sec, usec int64) Timeval { 15 | return Timeval{Sec: sec, Usec: int32(usec)} 16 | } 17 | 18 | func SetKevent(k *Kevent_t, fd, mode, flags int) { 19 | k.Ident = uint32(fd) 20 | k.Filter = uint32(mode) 21 | k.Flags = uint32(flags) 22 | } 23 | 24 | func (iov *Iovec) SetLen(length int) { 25 | iov.Len = uint32(length) 26 | } 27 | 28 | func (msghdr *Msghdr) SetControllen(length int) { 29 | msghdr.Controllen = uint32(length) 30 | } 31 | 32 | func (msghdr *Msghdr) SetIovlen(length int) { 33 | msghdr.Iovlen = int32(length) 34 | } 35 | 36 | func (cmsg *Cmsghdr) SetLen(length int) { 37 | cmsg.Len = uint32(length) 38 | } 39 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_netbsd_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build amd64 && netbsd 6 | // +build amd64,netbsd 7 | 8 | package unix 9 | 10 | func setTimespec(sec, nsec int64) Timespec { 11 | return Timespec{Sec: sec, Nsec: nsec} 12 | } 13 | 14 | func setTimeval(sec, usec int64) Timeval { 15 | return Timeval{Sec: sec, Usec: int32(usec)} 16 | } 17 | 18 | func SetKevent(k *Kevent_t, fd, mode, flags int) { 19 | k.Ident = uint64(fd) 20 | k.Filter = uint32(mode) 21 | k.Flags = uint32(flags) 22 | } 23 | 24 | func (iov *Iovec) SetLen(length int) { 25 | iov.Len = uint64(length) 26 | } 27 | 28 | func (msghdr *Msghdr) SetControllen(length int) { 29 | msghdr.Controllen = uint32(length) 30 | } 31 | 32 | func (msghdr *Msghdr) SetIovlen(length int) { 33 | msghdr.Iovlen = int32(length) 34 | } 35 | 36 | func (cmsg *Cmsghdr) SetLen(length int) { 37 | cmsg.Len = uint32(length) 38 | } 39 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_netbsd_arm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build arm && netbsd 6 | // +build arm,netbsd 7 | 8 | package unix 9 | 10 | func setTimespec(sec, nsec int64) Timespec { 11 | return Timespec{Sec: sec, Nsec: int32(nsec)} 12 | } 13 | 14 | func setTimeval(sec, usec int64) Timeval { 15 | return Timeval{Sec: sec, Usec: int32(usec)} 16 | } 17 | 18 | func SetKevent(k *Kevent_t, fd, mode, flags int) { 19 | k.Ident = uint32(fd) 20 | k.Filter = uint32(mode) 21 | k.Flags = uint32(flags) 22 | } 23 | 24 | func (iov *Iovec) SetLen(length int) { 25 | iov.Len = uint32(length) 26 | } 27 | 28 | func (msghdr *Msghdr) SetControllen(length int) { 29 | msghdr.Controllen = uint32(length) 30 | } 31 | 32 | func (msghdr *Msghdr) SetIovlen(length int) { 33 | msghdr.Iovlen = int32(length) 34 | } 35 | 36 | func (cmsg *Cmsghdr) SetLen(length int) { 37 | cmsg.Len = uint32(length) 38 | } 39 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_netbsd_arm64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build arm64 && netbsd 6 | // +build arm64,netbsd 7 | 8 | package unix 9 | 10 | func setTimespec(sec, nsec int64) Timespec { 11 | return Timespec{Sec: sec, Nsec: nsec} 12 | } 13 | 14 | func setTimeval(sec, usec int64) Timeval { 15 | return Timeval{Sec: sec, Usec: int32(usec)} 16 | } 17 | 18 | func SetKevent(k *Kevent_t, fd, mode, flags int) { 19 | k.Ident = uint64(fd) 20 | k.Filter = uint32(mode) 21 | k.Flags = uint32(flags) 22 | } 23 | 24 | func (iov *Iovec) SetLen(length int) { 25 | iov.Len = uint64(length) 26 | } 27 | 28 | func (msghdr *Msghdr) SetControllen(length int) { 29 | msghdr.Controllen = uint32(length) 30 | } 31 | 32 | func (msghdr *Msghdr) SetIovlen(length int) { 33 | msghdr.Iovlen = int32(length) 34 | } 35 | 36 | func (cmsg *Cmsghdr) SetLen(length int) { 37 | cmsg.Len = uint32(length) 38 | } 39 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_openbsd_mips64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package unix 6 | 7 | func setTimespec(sec, nsec int64) Timespec { 8 | return Timespec{Sec: sec, Nsec: nsec} 9 | } 10 | 11 | func setTimeval(sec, usec int64) Timeval { 12 | return Timeval{Sec: sec, Usec: usec} 13 | } 14 | 15 | func SetKevent(k *Kevent_t, fd, mode, flags int) { 16 | k.Ident = uint64(fd) 17 | k.Filter = int16(mode) 18 | k.Flags = uint16(flags) 19 | } 20 | 21 | func (iov *Iovec) SetLen(length int) { 22 | iov.Len = uint64(length) 23 | } 24 | 25 | func (msghdr *Msghdr) SetControllen(length int) { 26 | msghdr.Controllen = uint32(length) 27 | } 28 | 29 | func (cmsg *Cmsghdr) SetLen(length int) { 30 | cmsg.Len = uint32(length) 31 | } 32 | 33 | // SYS___SYSCTL is used by syscall_bsd.go for all BSDs, but in modern versions 34 | // of OpenBSD the syscall is called sysctl instead of __sysctl. 35 | const SYS___SYSCTL = SYS_SYSCTL 36 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_solaris_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build amd64 && solaris 6 | // +build amd64,solaris 7 | 8 | package unix 9 | 10 | func setTimespec(sec, nsec int64) Timespec { 11 | return Timespec{Sec: sec, Nsec: nsec} 12 | } 13 | 14 | func setTimeval(sec, usec int64) Timeval { 15 | return Timeval{Sec: sec, Usec: usec} 16 | } 17 | 18 | func (iov *Iovec) SetLen(length int) { 19 | iov.Len = uint64(length) 20 | } 21 | 22 | func (msghdr *Msghdr) SetIovlen(length int) { 23 | msghdr.Iovlen = int32(length) 24 | } 25 | 26 | func (cmsg *Cmsghdr) SetLen(length int) { 27 | cmsg.Len = uint32(length) 28 | } 29 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_unix_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris) && gc && !ppc64le && !ppc64 6 | // +build darwin dragonfly freebsd linux netbsd openbsd solaris 7 | // +build gc 8 | // +build !ppc64le 9 | // +build !ppc64 10 | 11 | package unix 12 | 13 | import "syscall" 14 | 15 | func Syscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) 16 | func Syscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) 17 | func RawSyscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) 18 | func RawSyscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) 19 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_unix_gc_ppc64x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && (ppc64le || ppc64) && gc 6 | // +build linux 7 | // +build ppc64le ppc64 8 | // +build gc 9 | 10 | package unix 11 | 12 | import "syscall" 13 | 14 | func Syscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) { 15 | return syscall.Syscall(trap, a1, a2, a3) 16 | } 17 | func Syscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) { 18 | return syscall.Syscall6(trap, a1, a2, a3, a4, a5, a6) 19 | } 20 | func RawSyscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) { 21 | return syscall.RawSyscall(trap, a1, a2, a3) 22 | } 23 | func RawSyscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) { 24 | return syscall.RawSyscall6(trap, a1, a2, a3, a4, a5, a6) 25 | } 26 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/zptrace_linux_arm64.go: -------------------------------------------------------------------------------- 1 | // Code generated by linux/mkall.go generatePtraceRegSet("arm64"). DO NOT EDIT. 2 | 3 | package unix 4 | 5 | import "unsafe" 6 | 7 | // PtraceGetRegSetArm64 fetches the registers used by arm64 binaries. 8 | func PtraceGetRegSetArm64(pid, addr int, regsout *PtraceRegsArm64) error { 9 | iovec := Iovec{(*byte)(unsafe.Pointer(regsout)), uint64(unsafe.Sizeof(*regsout))} 10 | return ptrace(PTRACE_GETREGSET, pid, uintptr(addr), uintptr(unsafe.Pointer(&iovec))) 11 | } 12 | 13 | // PtraceSetRegSetArm64 sets the registers used by arm64 binaries. 14 | func PtraceSetRegSetArm64(pid, addr int, regs *PtraceRegsArm64) error { 15 | iovec := Iovec{(*byte)(unsafe.Pointer(regs)), uint64(unsafe.Sizeof(*regs))} 16 | return ptrace(PTRACE_SETREGSET, pid, uintptr(addr), uintptr(unsafe.Pointer(&iovec))) 17 | } 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.1_13.s: -------------------------------------------------------------------------------- 1 | // go run mkasm_darwin.go amd64 2 | // Code generated by the command above; DO NOT EDIT. 3 | 4 | //go:build go1.13 5 | // +build go1.13 6 | 7 | #include "textflag.h" 8 | 9 | TEXT libc_fdopendir_trampoline<>(SB),NOSPLIT,$0-0 10 | JMP libc_fdopendir(SB) 11 | 12 | GLOBL ·libc_fdopendir_trampoline_addr(SB), RODATA, $8 13 | DATA ·libc_fdopendir_trampoline_addr(SB)/8, $libc_fdopendir_trampoline<>(SB) 14 | 15 | TEXT libc_closedir_trampoline<>(SB),NOSPLIT,$0-0 16 | JMP libc_closedir(SB) 17 | 18 | GLOBL ·libc_closedir_trampoline_addr(SB), RODATA, $8 19 | DATA ·libc_closedir_trampoline_addr(SB)/8, $libc_closedir_trampoline<>(SB) 20 | 21 | TEXT libc_readdir_r_trampoline<>(SB),NOSPLIT,$0-0 22 | JMP libc_readdir_r(SB) 23 | 24 | GLOBL ·libc_readdir_r_trampoline_addr(SB), RODATA, $8 25 | DATA ·libc_readdir_r_trampoline_addr(SB)/8, $libc_readdir_r_trampoline<>(SB) 26 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.1_13.s: -------------------------------------------------------------------------------- 1 | // go run mkasm_darwin.go arm64 2 | // Code generated by the command above; DO NOT EDIT. 3 | 4 | //go:build go1.13 5 | // +build go1.13 6 | 7 | #include "textflag.h" 8 | 9 | TEXT libc_fdopendir_trampoline<>(SB),NOSPLIT,$0-0 10 | JMP libc_fdopendir(SB) 11 | 12 | GLOBL ·libc_fdopendir_trampoline_addr(SB), RODATA, $8 13 | DATA ·libc_fdopendir_trampoline_addr(SB)/8, $libc_fdopendir_trampoline<>(SB) 14 | 15 | TEXT libc_closedir_trampoline<>(SB),NOSPLIT,$0-0 16 | JMP libc_closedir(SB) 17 | 18 | GLOBL ·libc_closedir_trampoline_addr(SB), RODATA, $8 19 | DATA ·libc_closedir_trampoline_addr(SB)/8, $libc_closedir_trampoline<>(SB) 20 | 21 | TEXT libc_readdir_r_trampoline<>(SB),NOSPLIT,$0-0 22 | JMP libc_readdir_r(SB) 23 | 24 | GLOBL ·libc_readdir_r_trampoline_addr(SB), RODATA, $8 25 | DATA ·libc_readdir_r_trampoline_addr(SB)/8, $libc_readdir_r_trampoline<>(SB) 26 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/ztypes_illumos_amd64.go: -------------------------------------------------------------------------------- 1 | // cgo -godefs types_illumos.go | go run mkpost.go 2 | // Code generated by the command above; see README.md. DO NOT EDIT. 3 | 4 | //go:build amd64 && illumos 5 | // +build amd64,illumos 6 | 7 | package unix 8 | 9 | const ( 10 | TUNNEWPPA = 0x540001 11 | TUNSETPPA = 0x540002 12 | 13 | I_STR = 0x5308 14 | I_POP = 0x5303 15 | I_PUSH = 0x5302 16 | I_PLINK = 0x5316 17 | I_PUNLINK = 0x5317 18 | 19 | IF_UNITSEL = -0x7ffb8cca 20 | ) 21 | 22 | type strbuf struct { 23 | Maxlen int32 24 | Len int32 25 | Buf *int8 26 | } 27 | 28 | type Strioctl struct { 29 | Cmd int32 30 | Timout int32 31 | Len int32 32 | Dp *int8 33 | } 34 | 35 | type Lifreq struct { 36 | Name [32]int8 37 | Lifru1 [4]byte 38 | Type uint32 39 | Lifru [336]byte 40 | } 41 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/encoding/japanese/all.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package japanese 6 | 7 | import ( 8 | "golang.org/x/text/encoding" 9 | ) 10 | 11 | // All is a list of all defined encodings in this package. 12 | var All = []encoding.Encoding{EUCJP, ISO2022JP, ShiftJIS} 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/encoding/simplifiedchinese/all.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package simplifiedchinese 6 | 7 | import ( 8 | "golang.org/x/text/encoding" 9 | ) 10 | 11 | // All is a list of all defined encodings in this package. 12 | var All = []encoding.Encoding{GB18030, GBK, HZGB2312} 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/internal/language/common.go: -------------------------------------------------------------------------------- 1 | // Code generated by running "go generate" in golang.org/x/text. DO NOT EDIT. 2 | 3 | package language 4 | 5 | // This file contains code common to the maketables.go and the package code. 6 | 7 | // AliasType is the type of an alias in AliasMap. 8 | type AliasType int8 9 | 10 | const ( 11 | Deprecated AliasType = iota 12 | Macro 13 | Legacy 14 | 15 | AliasTypeUnknown AliasType = -1 16 | ) 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/internal/language/compact.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package language 6 | 7 | // CompactCoreInfo is a compact integer with the three core tags encoded. 8 | type CompactCoreInfo uint32 9 | 10 | // GetCompactCore generates a uint32 value that is guaranteed to be unique for 11 | // different language, region, and script values. 12 | func GetCompactCore(t Tag) (cci CompactCoreInfo, ok bool) { 13 | if t.LangID > langNoIndexOffset { 14 | return 0, false 15 | } 16 | cci |= CompactCoreInfo(t.LangID) << (8 + 12) 17 | cci |= CompactCoreInfo(t.ScriptID) << 12 18 | cci |= CompactCoreInfo(t.RegionID) 19 | return cci, true 20 | } 21 | 22 | // Tag generates a tag from c. 23 | func (c CompactCoreInfo) Tag() Tag { 24 | return Tag{ 25 | LangID: Language(c >> 20), 26 | RegionID: Region(c & 0x3ff), 27 | ScriptID: Script(c>>12) & 0xff, 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/internal/language/coverage.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package language 6 | 7 | // BaseLanguages returns the list of all supported base languages. It generates 8 | // the list by traversing the internal structures. 9 | func BaseLanguages() []Language { 10 | base := make([]Language, 0, NumLanguages) 11 | for i := 0; i < langNoIndexOffset; i++ { 12 | // We included "und" already for the value 0. 13 | if i != nonCanonicalUnd { 14 | base = append(base, Language(i)) 15 | } 16 | } 17 | i := langNoIndexOffset 18 | for _, v := range langNoIndex { 19 | for k := 0; k < 8; k++ { 20 | if v&1 == 1 { 21 | base = append(base, Language(i)) 22 | } 23 | v >>= 1 24 | i++ 25 | } 26 | } 27 | return base 28 | } 29 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/language/go1_1.go: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !go1.2 6 | // +build !go1.2 7 | 8 | package language 9 | 10 | import "sort" 11 | 12 | func sortStable(s sort.Interface) { 13 | ss := stableSort{ 14 | s: s, 15 | pos: make([]int, s.Len()), 16 | } 17 | for i := range ss.pos { 18 | ss.pos[i] = i 19 | } 20 | sort.Sort(&ss) 21 | } 22 | 23 | type stableSort struct { 24 | s sort.Interface 25 | pos []int 26 | } 27 | 28 | func (s *stableSort) Len() int { 29 | return len(s.pos) 30 | } 31 | 32 | func (s *stableSort) Less(i, j int) bool { 33 | return s.s.Less(i, j) || !s.s.Less(j, i) && s.pos[i] < s.pos[j] 34 | } 35 | 36 | func (s *stableSort) Swap(i, j int) { 37 | s.s.Swap(i, j) 38 | s.pos[i], s.pos[j] = s.pos[j], s.pos[i] 39 | } 40 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/language/go1_2.go: -------------------------------------------------------------------------------- 1 | // Copyright 2013 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build go1.2 6 | // +build go1.2 7 | 8 | package language 9 | 10 | import "sort" 11 | 12 | var sortStable = sort.Stable 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at http://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at http://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/go/ast/astutil/util.go: -------------------------------------------------------------------------------- 1 | package astutil 2 | 3 | import "go/ast" 4 | 5 | // Unparen returns e with any enclosing parentheses stripped. 6 | func Unparen(e ast.Expr) ast.Expr { 7 | for { 8 | p, ok := e.(*ast.ParenExpr) 9 | if !ok { 10 | return e 11 | } 12 | e = p.X 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/go/internal/gcimporter/newInterface10.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !go1.11 6 | 7 | package gcimporter 8 | 9 | import "go/types" 10 | 11 | func newInterface(methods []*types.Func, embeddeds []types.Type) *types.Interface { 12 | named := make([]*types.Named, len(embeddeds)) 13 | for i, e := range embeddeds { 14 | var ok bool 15 | named[i], ok = e.(*types.Named) 16 | if !ok { 17 | panic("embedding of non-defined interfaces in interfaces is not supported before Go 1.11") 18 | } 19 | } 20 | return types.NewInterface(methods, named) 21 | } 22 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/go/internal/gcimporter/newInterface11.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build go1.11 6 | 7 | package gcimporter 8 | 9 | import "go/types" 10 | 11 | func newInterface(methods []*types.Func, embeddeds []types.Type) *types.Interface { 12 | return types.NewInterfaceType(methods, embeddeds) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/go/types/typeutil/imports.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package typeutil 6 | 7 | import "go/types" 8 | 9 | // Dependencies returns all dependencies of the specified packages. 10 | // 11 | // Dependent packages appear in topological order: if package P imports 12 | // package Q, Q appears earlier than P in the result. 13 | // The algorithm follows import statements in the order they 14 | // appear in the source code, so the result is a total order. 15 | // 16 | func Dependencies(pkgs ...*types.Package) []*types.Package { 17 | var result []*types.Package 18 | seen := make(map[*types.Package]bool) 19 | var visit func(pkgs []*types.Package) 20 | visit = func(pkgs []*types.Package) { 21 | for _, p := range pkgs { 22 | if !seen[p] { 23 | seen[p] = true 24 | visit(p.Imports()) 25 | result = append(result, p) 26 | } 27 | } 28 | } 29 | visit(pkgs) 30 | return result 31 | } 32 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/event/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package event provides a set of packages that cover the main 6 | // concepts of telemetry in an implementation agnostic way. 7 | package event 8 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/event/keys/standard.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package keys 6 | 7 | var ( 8 | // Msg is a key used to add message strings to label lists. 9 | Msg = NewString("message", "a readable message") 10 | // Label is a key used to indicate an event adds labels to the context. 11 | Label = NewTag("label", "a label context marker") 12 | // Start is used for things like traces that have a name. 13 | Start = NewString("start", "span start") 14 | // Metric is a key used to indicate an event records metrics. 15 | End = NewTag("end", "a span end marker") 16 | // Metric is a key used to indicate an event records metrics. 17 | Detach = NewTag("detach", "a span detach marker") 18 | // Err is a key used to add error values to label lists. 19 | Err = NewError("error", "an error that occurred") 20 | // Metric is a key used to indicate an event records metrics. 21 | Metric = NewTag("metric", "a metric event marker") 22 | ) 23 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/fastwalk/fastwalk_dirent_fileno.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build freebsd openbsd netbsd 6 | 7 | package fastwalk 8 | 9 | import "syscall" 10 | 11 | func direntInode(dirent *syscall.Dirent) uint64 { 12 | return uint64(dirent.Fileno) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/fastwalk/fastwalk_dirent_ino.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build linux darwin 6 | // +build !appengine 7 | 8 | package fastwalk 9 | 10 | import "syscall" 11 | 12 | func direntInode(dirent *syscall.Dirent) uint64 { 13 | return uint64(dirent.Ino) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/fastwalk/fastwalk_dirent_namlen_bsd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build darwin freebsd openbsd netbsd 6 | 7 | package fastwalk 8 | 9 | import "syscall" 10 | 11 | func direntNamlen(dirent *syscall.Dirent) uint64 { 12 | return uint64(dirent.Namlen) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/fastwalk/fastwalk_dirent_namlen_linux.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build linux 6 | // +build !appengine 7 | 8 | package fastwalk 9 | 10 | import ( 11 | "bytes" 12 | "syscall" 13 | "unsafe" 14 | ) 15 | 16 | func direntNamlen(dirent *syscall.Dirent) uint64 { 17 | const fixedHdr = uint16(unsafe.Offsetof(syscall.Dirent{}.Name)) 18 | nameBuf := (*[unsafe.Sizeof(dirent.Name)]byte)(unsafe.Pointer(&dirent.Name[0])) 19 | const nameBufLen = uint16(len(nameBuf)) 20 | limit := dirent.Reclen - fixedHdr 21 | if limit > nameBufLen { 22 | limit = nameBufLen 23 | } 24 | nameLen := bytes.IndexByte(nameBuf[:limit], 0) 25 | if nameLen < 0 { 26 | panic("failed to find terminating 0 byte in dirent") 27 | } 28 | return uint64(nameLen) 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/fastwalk/fastwalk_portable.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build appengine !linux,!darwin,!freebsd,!openbsd,!netbsd 6 | 7 | package fastwalk 8 | 9 | import ( 10 | "io/ioutil" 11 | "os" 12 | ) 13 | 14 | // readDir calls fn for each directory entry in dirName. 15 | // It does not descend into directories or follow symlinks. 16 | // If fn returns a non-nil error, readDir returns with that error 17 | // immediately. 18 | func readDir(dirName string, fn func(dirName, entName string, typ os.FileMode) error) error { 19 | fis, err := ioutil.ReadDir(dirName) 20 | if err != nil { 21 | return err 22 | } 23 | skipFiles := false 24 | for _, fi := range fis { 25 | if fi.Mode().IsRegular() && skipFiles { 26 | continue 27 | } 28 | if err := fn(dirName, fi.Name(), fi.Mode()&os.ModeType); err != nil { 29 | if err == ErrSkipFiles { 30 | skipFiles = true 31 | continue 32 | } 33 | return err 34 | } 35 | } 36 | return nil 37 | } 38 | -------------------------------------------------------------------------------- /vendor/golang.org/x/tools/internal/packagesinternal/packages.go: -------------------------------------------------------------------------------- 1 | // Package packagesinternal exposes internal-only fields from go/packages. 2 | package packagesinternal 3 | 4 | import ( 5 | "golang.org/x/tools/internal/gocommand" 6 | ) 7 | 8 | var GetForTest = func(p interface{}) string { return "" } 9 | 10 | var GetGoCmdRunner = func(config interface{}) *gocommand.Runner { return nil } 11 | 12 | var SetGoCmdRunner = func(config interface{}, runner *gocommand.Runner) {} 13 | 14 | var TypecheckCgo int 15 | 16 | var SetModFlag = func(config interface{}, value string) {} 17 | var SetModFile = func(config interface{}, value string) {} 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/xerrors/README: -------------------------------------------------------------------------------- 1 | This repository holds the transition packages for the new Go 1.13 error values. 2 | See golang.org/design/29934-error-values. 3 | -------------------------------------------------------------------------------- /vendor/golang.org/x/xerrors/codereview.cfg: -------------------------------------------------------------------------------- 1 | issuerepo: golang/go 2 | -------------------------------------------------------------------------------- /vendor/golang.org/x/xerrors/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package xerrors implements functions to manipulate errors. 6 | // 7 | // This package is based on the Go 2 proposal for error values: 8 | // https://golang.org/design/29934-error-values 9 | // 10 | // These functions were incorporated into the standard library's errors package 11 | // in Go 1.13: 12 | // - Is 13 | // - As 14 | // - Unwrap 15 | // 16 | // Also, Errorf's %w verb was incorporated into fmt.Errorf. 17 | // 18 | // Use this package to get equivalent behavior in all supported Go versions. 19 | // 20 | // No other features of this package were included in Go 1.13, and at present 21 | // there are no plans to include any of them. 22 | package xerrors // import "golang.org/x/xerrors" 23 | -------------------------------------------------------------------------------- /vendor/golang.org/x/xerrors/errors.go: -------------------------------------------------------------------------------- 1 | // Copyright 2011 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package xerrors 6 | 7 | import "fmt" 8 | 9 | // errorString is a trivial implementation of error. 10 | type errorString struct { 11 | s string 12 | frame Frame 13 | } 14 | 15 | // New returns an error that formats as the given text. 16 | // 17 | // The returned error contains a Frame set to the caller's location and 18 | // implements Formatter to show this information when printed with details. 19 | func New(text string) error { 20 | return &errorString{text, Caller(1)} 21 | } 22 | 23 | func (e *errorString) Error() string { 24 | return e.s 25 | } 26 | 27 | func (e *errorString) Format(s fmt.State, v rune) { FormatError(e, s, v) } 28 | 29 | func (e *errorString) FormatError(p Printer) (next error) { 30 | p.Print(e.s) 31 | e.frame.Format(p) 32 | return nil 33 | } 34 | -------------------------------------------------------------------------------- /vendor/golang.org/x/xerrors/go.mod: -------------------------------------------------------------------------------- 1 | module golang.org/x/xerrors 2 | 3 | go 1.11 4 | -------------------------------------------------------------------------------- /vendor/golang.org/x/xerrors/internal/internal.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package internal 6 | 7 | // EnableTrace indicates whether stack information should be recorded in errors. 8 | var EnableTrace = true 9 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at https://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at https://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/encoding/prototext/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package prototext marshals and unmarshals protocol buffer messages as the 6 | // textproto format. 7 | package prototext 8 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/errors/is_go112.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !go1.13 6 | 7 | package errors 8 | 9 | import "reflect" 10 | 11 | // Is is a copy of Go 1.13's errors.Is for use with older Go versions. 12 | func Is(err, target error) bool { 13 | if target == nil { 14 | return err == target 15 | } 16 | 17 | isComparable := reflect.TypeOf(target).Comparable() 18 | for { 19 | if isComparable && err == target { 20 | return true 21 | } 22 | if x, ok := err.(interface{ Is(error) bool }); ok && x.Is(target) { 23 | return true 24 | } 25 | if err = unwrap(err); err == nil { 26 | return false 27 | } 28 | } 29 | } 30 | 31 | func unwrap(err error) error { 32 | u, ok := err.(interface { 33 | Unwrap() error 34 | }) 35 | if !ok { 36 | return nil 37 | } 38 | return u.Unwrap() 39 | } 40 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/errors/is_go113.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build go1.13 6 | 7 | package errors 8 | 9 | import "errors" 10 | 11 | // Is is errors.Is. 12 | func Is(err, target error) bool { return errors.Is(err, target) } 13 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/flags/proto_legacy_disable.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !protolegacy 6 | 7 | package flags 8 | 9 | const protoLegacy = false 10 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/flags/proto_legacy_enable.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build protolegacy 6 | 7 | package flags 8 | 9 | const protoLegacy = true 10 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package genid contains constants for declarations in descriptor.proto 6 | // and the well-known types. 7 | package genid 8 | 9 | import protoreflect "google.golang.org/protobuf/reflect/protoreflect" 10 | 11 | const GoogleProtobuf_package protoreflect.FullName = "google.protobuf" 12 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/empty_gen.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Code generated by generate-protos. DO NOT EDIT. 6 | 7 | package genid 8 | 9 | import ( 10 | protoreflect "google.golang.org/protobuf/reflect/protoreflect" 11 | ) 12 | 13 | const File_google_protobuf_empty_proto = "google/protobuf/empty.proto" 14 | 15 | // Names for google.protobuf.Empty. 16 | const ( 17 | Empty_message_name protoreflect.Name = "Empty" 18 | Empty_message_fullname protoreflect.FullName = "google.protobuf.Empty" 19 | ) 20 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/field_mask_gen.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Code generated by generate-protos. DO NOT EDIT. 6 | 7 | package genid 8 | 9 | import ( 10 | protoreflect "google.golang.org/protobuf/reflect/protoreflect" 11 | ) 12 | 13 | const File_google_protobuf_field_mask_proto = "google/protobuf/field_mask.proto" 14 | 15 | // Names for google.protobuf.FieldMask. 16 | const ( 17 | FieldMask_message_name protoreflect.Name = "FieldMask" 18 | FieldMask_message_fullname protoreflect.FullName = "google.protobuf.FieldMask" 19 | ) 20 | 21 | // Field names for google.protobuf.FieldMask. 22 | const ( 23 | FieldMask_Paths_field_name protoreflect.Name = "paths" 24 | 25 | FieldMask_Paths_field_fullname protoreflect.FullName = "google.protobuf.FieldMask.paths" 26 | ) 27 | 28 | // Field numbers for google.protobuf.FieldMask. 29 | const ( 30 | FieldMask_Paths_field_number protoreflect.FieldNumber = 1 31 | ) 32 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/goname.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package genid 6 | 7 | // Go names of implementation-specific struct fields in generated messages. 8 | const ( 9 | State_goname = "state" 10 | 11 | SizeCache_goname = "sizeCache" 12 | SizeCacheA_goname = "XXX_sizecache" 13 | 14 | WeakFields_goname = "weakFields" 15 | WeakFieldsA_goname = "XXX_weak" 16 | 17 | UnknownFields_goname = "unknownFields" 18 | UnknownFieldsA_goname = "XXX_unrecognized" 19 | 20 | ExtensionFields_goname = "extensionFields" 21 | ExtensionFieldsA_goname = "XXX_InternalExtensions" 22 | ExtensionFieldsB_goname = "XXX_extensions" 23 | 24 | WeakFieldPrefix_goname = "XXX_weak_" 25 | ) 26 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/map_entry.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package genid 6 | 7 | import protoreflect "google.golang.org/protobuf/reflect/protoreflect" 8 | 9 | // Generic field names and numbers for synthetic map entry messages. 10 | const ( 11 | MapEntry_Key_field_name protoreflect.Name = "key" 12 | MapEntry_Value_field_name protoreflect.Name = "value" 13 | 14 | MapEntry_Key_field_number protoreflect.FieldNumber = 1 15 | MapEntry_Value_field_number protoreflect.FieldNumber = 2 16 | ) 17 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/wrappers.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package genid 6 | 7 | import protoreflect "google.golang.org/protobuf/reflect/protoreflect" 8 | 9 | // Generic field name and number for messages in wrappers.proto. 10 | const ( 11 | WrapperValue_Value_field_name protoreflect.Name = "value" 12 | WrapperValue_Value_field_number protoreflect.FieldNumber = 1 13 | ) 14 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/impl/codec_map_go111.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !go1.12 6 | 7 | package impl 8 | 9 | import "reflect" 10 | 11 | type mapIter struct { 12 | v reflect.Value 13 | keys []reflect.Value 14 | } 15 | 16 | // mapRange provides a less-efficient equivalent to 17 | // the Go 1.12 reflect.Value.MapRange method. 18 | func mapRange(v reflect.Value) *mapIter { 19 | return &mapIter{v: v} 20 | } 21 | 22 | func (i *mapIter) Next() bool { 23 | if i.keys == nil { 24 | i.keys = i.v.MapKeys() 25 | } else { 26 | i.keys = i.keys[1:] 27 | } 28 | return len(i.keys) > 0 29 | } 30 | 31 | func (i *mapIter) Key() reflect.Value { 32 | return i.keys[0] 33 | } 34 | 35 | func (i *mapIter) Value() reflect.Value { 36 | return i.v.MapIndex(i.keys[0]) 37 | } 38 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/impl/codec_map_go112.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build go1.12 6 | 7 | package impl 8 | 9 | import "reflect" 10 | 11 | func mapRange(v reflect.Value) *reflect.MapIter { return v.MapRange() } 12 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/impl/codec_unsafe.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !purego,!appengine 6 | 7 | package impl 8 | 9 | // When using unsafe pointers, we can just treat enum values as int32s. 10 | 11 | var ( 12 | coderEnumNoZero = coderInt32NoZero 13 | coderEnum = coderInt32 14 | coderEnumPtr = coderInt32Ptr 15 | coderEnumSlice = coderInt32Slice 16 | coderEnumPackedSlice = coderInt32PackedSlice 17 | ) 18 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/impl/enum.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package impl 6 | 7 | import ( 8 | "reflect" 9 | 10 | pref "google.golang.org/protobuf/reflect/protoreflect" 11 | ) 12 | 13 | type EnumInfo struct { 14 | GoReflectType reflect.Type // int32 kind 15 | Desc pref.EnumDescriptor 16 | } 17 | 18 | func (t *EnumInfo) New(n pref.EnumNumber) pref.Enum { 19 | return reflect.ValueOf(n).Convert(t.GoReflectType).Interface().(pref.Enum) 20 | } 21 | func (t *EnumInfo) Descriptor() pref.EnumDescriptor { return t.Desc } 22 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/strs/strings_pure.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build purego appengine 6 | 7 | package strs 8 | 9 | import pref "google.golang.org/protobuf/reflect/protoreflect" 10 | 11 | func UnsafeString(b []byte) string { 12 | return string(b) 13 | } 14 | 15 | func UnsafeBytes(s string) []byte { 16 | return []byte(s) 17 | } 18 | 19 | type Builder struct{} 20 | 21 | func (*Builder) AppendFullName(prefix pref.FullName, name pref.Name) pref.FullName { 22 | return prefix.Append(name) 23 | } 24 | 25 | func (*Builder) MakeString(b []byte) string { 26 | return string(b) 27 | } 28 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/proto/proto_methods.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // The protoreflect build tag disables use of fast-path methods. 6 | // +build !protoreflect 7 | 8 | package proto 9 | 10 | import ( 11 | "google.golang.org/protobuf/reflect/protoreflect" 12 | "google.golang.org/protobuf/runtime/protoiface" 13 | ) 14 | 15 | const hasProtoMethods = true 16 | 17 | func protoMethods(m protoreflect.Message) *protoiface.Methods { 18 | return m.ProtoMethods() 19 | } 20 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/proto/proto_reflect.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // The protoreflect build tag disables use of fast-path methods. 6 | // +build protoreflect 7 | 8 | package proto 9 | 10 | import ( 11 | "google.golang.org/protobuf/reflect/protoreflect" 12 | "google.golang.org/protobuf/runtime/protoiface" 13 | ) 14 | 15 | const hasProtoMethods = false 16 | 17 | func protoMethods(m protoreflect.Message) *protoiface.Methods { 18 | return nil 19 | } 20 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/runtime/protoiface/legacy.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package protoiface 6 | 7 | type MessageV1 interface { 8 | Reset() 9 | String() string 10 | ProtoMessage() 11 | } 12 | 13 | type ExtensionRangeV1 struct { 14 | Start, End int32 // both inclusive 15 | } 16 | -------------------------------------------------------------------------------- /vendor/gopkg.in/tomb.v1/README.md: -------------------------------------------------------------------------------- 1 | Installation and usage 2 | ---------------------- 3 | 4 | See [gopkg.in/tomb.v1](https://gopkg.in/tomb.v1) for documentation and usage details. 5 | -------------------------------------------------------------------------------- /vendor/gopkg.in/validator.v2/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | -------------------------------------------------------------------------------- /vendor/gopkg.in/validator.v2/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - "1.10" 4 | - 1.11 5 | - 1.12 6 | - tip 7 | go_import_path: gopkg.in/validator.v2 8 | script: 9 | - go test -race -v -bench=. 10 | notifications: 11 | email: false 12 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - "1.4.x" 5 | - "1.5.x" 6 | - "1.6.x" 7 | - "1.7.x" 8 | - "1.8.x" 9 | - "1.9.x" 10 | - "1.10.x" 11 | - "1.11.x" 12 | - "1.12.x" 13 | - "1.13.x" 14 | - "1.14.x" 15 | - "tip" 16 | 17 | go_import_path: gopkg.in/yaml.v2 18 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/NOTICE: -------------------------------------------------------------------------------- 1 | Copyright 2011-2016 Canonical Ltd. 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/go.mod: -------------------------------------------------------------------------------- 1 | module gopkg.in/yaml.v2 2 | 3 | go 1.15 4 | 5 | require gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 6 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/writerc.go: -------------------------------------------------------------------------------- 1 | package yaml 2 | 3 | // Set the writer error and return false. 4 | func yaml_emitter_set_writer_error(emitter *yaml_emitter_t, problem string) bool { 5 | emitter.error = yaml_WRITER_ERROR 6 | emitter.problem = problem 7 | return false 8 | } 9 | 10 | // Flush the output buffer. 11 | func yaml_emitter_flush(emitter *yaml_emitter_t) bool { 12 | if emitter.write_handler == nil { 13 | panic("write handler not set") 14 | } 15 | 16 | // Check if the buffer is empty. 17 | if emitter.buffer_pos == 0 { 18 | return true 19 | } 20 | 21 | if err := emitter.write_handler(emitter, emitter.buffer[:emitter.buffer_pos]); err != nil { 22 | return yaml_emitter_set_writer_error(emitter, "write error: "+err.Error()) 23 | } 24 | emitter.buffer_pos = 0 25 | return true 26 | } 27 | --------------------------------------------------------------------------------