Skip to content
This repository was archived by the owner on Oct 27, 2022. It is now read-only.

Commit 4d261a1

Browse files
committed
Initial commit with stubs
0 parents  commit 4d261a1

File tree

19 files changed

+685
-0
lines changed

19 files changed

+685
-0
lines changed

.gitignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/.bundle/
2+
/.yardoc
3+
/Gemfile.lock
4+
/_yardoc/
5+
/coverage/
6+
/doc/
7+
/pkg/
8+
/spec/reports/
9+
/tmp/
10+
11+
/docs/_site
12+
/docs/Gemfile.lock
13+
/docs/api/

.rubocop.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
AllCops:
2+
Exclude:
3+
- "acceptance/**/*"
4+
- "integration/**/*"
5+
- "opencensus-ocagent.gemspec"
6+
- "Rakefile"
7+
- "support/**/*"
8+
- "test/**/*"
9+
- "docs/**/*"
10+
- "tmp/**/*"
11+
TargetRubyVersion: 2.3
12+
Documentation:
13+
Enabled: false
14+
Layout/EmptyLines:
15+
Enabled: false
16+
Layout/SpaceAroundOperators:
17+
Enabled: false
18+
Metrics/AbcSize:
19+
Max: 25
20+
Metrics/ClassLength:
21+
Enabled: false
22+
Metrics/CyclomaticComplexity:
23+
Max: 10
24+
Metrics/MethodLength:
25+
Max: 20
26+
Metrics/ParameterLists:
27+
Enabled: false
28+
Metrics/PerceivedComplexity:
29+
Max: 10
30+
Naming/FileName:
31+
Exclude:
32+
- "lib/opencensus-ocagent.rb"
33+
Style/CaseEquality:
34+
Enabled: false
35+
Style/ClassVars:
36+
Enabled: false
37+
Style/EmptyElse:
38+
Enabled: false
39+
Style/GuardClause:
40+
Enabled: false
41+
Style/MethodDefParentheses:
42+
EnforcedStyle: require_no_parentheses
43+
Style/NumericLiterals:
44+
Enabled: false
45+
Style/RescueModifier:
46+
Enabled: false
47+
Style/StringLiterals:
48+
EnforcedStyle: double_quotes
49+
Style/TrivialAccessors:
50+
Enabled: false
51+
Style/WordArray:
52+
Enabled: false

.toys.rb

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
# frozen_string_literal: true
2+
3+
# Copyright 2019 Google LLC
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+
18+
expand :clean, paths: ["pkg", "doc", ".yardoc", "tmp"]
19+
20+
expand :minitest, libs: ["lib", "test"], files: ["test/**/*_test.rb"]
21+
22+
expand :rubocop
23+
24+
expand :yardoc do |t|
25+
t.generate_output_flag = true
26+
t.fail_on_warning = true
27+
t.fail_on_undocumented_objects = true
28+
end
29+
30+
expand :gem_build
31+
32+
expand :gem_build, name: "release", push_gem: true
33+
34+
tool "ci" do
35+
desc "Run all CI checks"
36+
37+
long_desc "The CI tool runs all CI checks for the gem, including unit" \
38+
" tests, rubocop, and documentation checks. It is useful for" \
39+
" running tests in normal development, as well as being the" \
40+
" entrypoint for CI systems such as Travis. Any failure will" \
41+
" result in a nonzero result code."
42+
43+
include :exec
44+
include :terminal
45+
46+
def run_stage name, tool
47+
if exec_tool(tool).success?
48+
puts "** #{name} passed\n\n", :green, :bold
49+
else
50+
puts "** CI terminated: #{name} failed!", :red, :bold
51+
exit 1
52+
end
53+
end
54+
55+
def run
56+
run_stage "Tests", ["test"]
57+
run_stage "Style checker", ["rubocop"]
58+
run_stage "Docs generation", ["yardoc", "--no-output"]
59+
end
60+
end

.yardopts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
--no-private
2+
--title=OpenCensus OCAgent Exporter
3+
--markup markdown
4+
--markup-provider redcarpet
5+
--main=README.md
6+
7+
./lib/**/*.rb
8+
-
9+
README.md
10+
CONTRIBUTING.md
11+
CHANGELOG.md

AUTHORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Google Inc.

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Release History

CODE_OF_CONDUCT.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# Contributor Code of Conduct
2+
3+
As contributors and maintainers of this project,
4+
and in the interest of fostering an open and welcoming community,
5+
we pledge to respect all people who contribute through reporting issues,
6+
posting feature requests, updating documentation,
7+
submitting pull requests or patches, and other activities.
8+
9+
We are committed to making participation in this project
10+
a harassment-free experience for everyone,
11+
regardless of level of experience, gender, gender identity and expression,
12+
sexual orientation, disability, personal appearance,
13+
body size, race, ethnicity, age, religion, or nationality.
14+
15+
Examples of unacceptable behavior by participants include:
16+
17+
* The use of sexualized language or imagery
18+
* Personal attacks
19+
* Trolling or insulting/derogatory comments
20+
* Public or private harassment
21+
* Publishing other's private information,
22+
such as physical or electronic
23+
addresses, without explicit permission
24+
* Other unethical or unprofessional conduct.
25+
26+
Project maintainers have the right and responsibility to remove, edit, or reject
27+
comments, commits, code, wiki edits, issues, and other contributions
28+
that are not aligned to this Code of Conduct.
29+
By adopting this Code of Conduct,
30+
project maintainers commit themselves to fairly and consistently
31+
applying these principles to every aspect of managing this project.
32+
Project maintainers who do not follow or enforce the Code of Conduct
33+
may be permanently removed from the project team.
34+
35+
This code of conduct applies both within project spaces and in public spaces
36+
when an individual is representing the project or its community.
37+
38+
Instances of abusive, harassing, or otherwise unacceptable behavior
39+
may be reported by opening an issue
40+
or contacting one or more of the project maintainers.
41+
42+
This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), version 1.2.0,
43+
available at [http://contributor-covenant.org/version/1/2/0/](http://contributor-covenant.org/version/1/2/0/)

CONTRIBUTING.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# How to become a contributor and submit your own code
2+
3+
## Contributor License Agreements
4+
5+
We'd love to accept your patches! Before we can take them, we
6+
have to jump a couple of legal hurdles.
7+
8+
Please fill out either the individual or corporate Contributor License Agreement
9+
(CLA).
10+
11+
* If you are an individual writing original source code and you're sure you
12+
own the intellectual property, then you'll need to sign an [individual CLA]
13+
(https://developers.google.com/open-source/cla/individual).
14+
* If you work for a company that wants to allow you to contribute your work,
15+
then you'll need to sign a [corporate CLA]
16+
(https://developers.google.com/open-source/cla/corporate).
17+
18+
Follow either of the two links above to access the appropriate CLA and
19+
instructions for how to sign and return it. Once we receive it, we'll be able to
20+
accept your pull requests.
21+
22+
## Contributing A Patch
23+
24+
1. Submit an issue describing your proposed change to the repo in question.
25+
1. The repo owner will respond to your issue promptly.
26+
1. If your proposed change is accepted, and you haven't already done so, sign a
27+
Contributor License Agreement (see details above).
28+
1. Fork the desired repo, develop and test your code changes.
29+
1. Ensure that your code adheres to the existing style in the sample to which
30+
you are contributing. Refer to the
31+
[Google Cloud Platform Samples Style Guide]
32+
(https://github.com/GoogleCloudPlatform/Template/wiki/style.html) for the
33+
recommended coding standards for this organization.
34+
1. Submit a pull request.

Gemfile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# frozen_string_literal: true
2+
3+
source "https://rubygems.org"
4+
gemspec

0 commit comments

Comments
 (0)