Skip to content

Commit 7a0862d

Browse files
authored
Merge pull request #6 from Logofile/staging
Staging the new site
2 parents ee4e6fd + 56a7f1b commit 7a0862d

File tree

621 files changed

+352755
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

621 files changed

+352755
-0
lines changed

.github/workflows/gh-pages.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: github pages
2+
3+
on:
4+
push:
5+
branches:
6+
- main # Set a branch to deploy
7+
pull_request:
8+
9+
jobs:
10+
deploy:
11+
runs-on: ubuntu-22.04
12+
steps:
13+
- uses: actions/checkout@v3
14+
with:
15+
submodules: true # Fetch Hugo themes (true OR recursive)
16+
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
17+
18+
- name: Setup Hugo
19+
uses: peaceiris/actions-hugo@v2
20+
with:
21+
hugo-version: 'latest'
22+
extended: true
23+
24+
- name: Install Dependencies
25+
run: npm install autoprefixer postcss postcss-cli
26+
27+
- name: Build
28+
run: hugo --minify
29+
30+
- name: Deploy
31+
uses: peaceiris/actions-gh-pages@v3
32+
if: github.ref == 'refs/heads/main'
33+
with:
34+
github_token: ${{ secrets.GITHUB_TOKEN }}
35+
publish_dir: ./public

CONTRIBUTING.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# How to Contribute
2+
3+
We'd love to accept your patches and contributions to this project. There are
4+
just a few small guidelines you need to follow.
5+
6+
## Contributor License Agreement
7+
8+
Contributions to this project must be accompanied by a Contributor License
9+
Agreement. You (or your employer) retain the copyright to your contribution;
10+
this simply gives us permission to use and redistribute your contributions as
11+
part of the project. Head over to <https://cla.developers.google.com/> to see
12+
your current agreements on file or to sign a new one.
13+
14+
You generally only need to submit a CLA once, so if you've already submitted one
15+
(even if it was for a different project), you probably don't need to do it
16+
again.
17+
18+
## Code Reviews
19+
20+
All submissions, including submissions by project members, require review. We
21+
use GitHub pull requests for this purpose. Consult
22+
[GitHub Help](https://help.github.com/articles/about-pull-requests/) for more
23+
information on using pull requests.
24+
25+
## Community Guidelines
26+
27+
This project follows [Google's Open Source Community
28+
Guidelines](https://opensource.google/conduct/).

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Protocol Buffers - Google's data interchange format
2+
3+
Copyright 2008 Google Inc.
4+
5+
https://protobuf.dev
6+
7+
## Overview
8+
9+
Protocol Buffers (a.k.a., protobuf) are Google's language-neutral,
10+
platform-neutral, extensible mechanism for serializing structured data. This
11+
site holds Protocol Buffers documentation.
12+
13+
## Protocol Buffers Repository
14+
15+
The Protocol Buffers GitHub repository is
16+
https://github.com/protocolbuffers/protobuf.
17+
18+
## Developer Community
19+
20+
To be alerted to upcoming changes in Protocol Buffers and connect with protobuf
21+
developers and users,
22+
[join the Google Group](https://groups.google.com/g/protobuf).

config.toml

Lines changed: 194 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,194 @@
1+
# baseURL = 'https://protobuf.dev'
2+
languageCode = 'en-us'
3+
title = 'Protocol Buffers Documentation'
4+
sidebar_search_disable = true
5+
6+
# Theme
7+
[module]
8+
[module.hugoVersion]
9+
extended = true
10+
min = "0.75.0"
11+
[[module.imports]]
12+
path = "github.com/google/docsy"
13+
disable = false
14+
[[module.imports]]
15+
path = "github.com/google/docsy/dependencies"
16+
disable = false
17+
18+
# Language settings
19+
contentDir = "content"
20+
defaultContentLanguage = "en"
21+
defaultContentLanguageInSubdir = false
22+
enableMissingTranslationPlaceholders = true
23+
enableRobotsTXT = true
24+
enableGitInfo = false
25+
26+
[taxonomies]
27+
tag = "tags"
28+
category = "categories"
29+
30+
[params.taxonomy]
31+
# set taxonomyCloud = [] to hide taxonomy clouds
32+
taxonomyCloud = ["tags", "categories"]
33+
34+
# Highlighting config
35+
pygmentsCodeFences = true
36+
pygmentsUseClasses = false
37+
# Use the new Chroma Go highlighter in Hugo.
38+
pygmentsUseClassic = false
39+
#pygmentsOptions = "linenos=table"
40+
# See https://help.farbox.com/pygments.html
41+
pygmentsStyle = "tango"
42+
43+
# Configure how URLs look like per section.
44+
[permalinks]
45+
blog = "/:section/:year/:month/:day/:slug/"
46+
47+
## Configuration for BlackFriday markdown parser: https://github.com/russross/blackfriday
48+
[blackfriday]
49+
plainIDAnchors = true
50+
hrefTargetBlank = true
51+
angledQuotes = false
52+
latexDashes = true
53+
smartypants = false
54+
55+
# Image processing configuration.
56+
[imaging]
57+
resampleFilter = "CatmullRom"
58+
quality = 75
59+
anchor = "smart"
60+
61+
[services]
62+
[services.googleAnalytics]
63+
id = "G-5L8P8GRN4Y"
64+
65+
# Language configuration
66+
67+
[languages]
68+
[languages.en]
69+
title = "Protocol Buffers Documentation"
70+
languageName ="English"
71+
# Weight used for sorting.
72+
weight = 1
73+
74+
75+
[markup]
76+
[markup.goldmark]
77+
[markup.goldmark.renderer]
78+
unsafe = true
79+
[markup.highlight]
80+
# See a complete list of available styles at https://xyproto.github.io/splash/docs/all.html
81+
style = "tango"
82+
# Uncomment if you want your chosen highlight style used for code blocks without a specified language
83+
# guessSyntax = "true"
84+
85+
# Everything below this are Site Params
86+
87+
# Comment out if you don't want the "print entire section" link enabled.
88+
[outputs]
89+
section = ["HTML", "print", "RSS"]
90+
91+
[params]
92+
description = "Protocol buffers is a language-neutral, platform-neutral extensible mechanism for serializing structured data."
93+
copyright = "Google LLC"
94+
privacy_policy = "https://policies.google.com/privacy"
95+
96+
# First one is picked as the Twitter card image if not set on page.
97+
# images = ["images/project-illustration.png"]
98+
99+
# Menu title if your navbar has a versions selector to access old versions of your site.
100+
# This menu appears only if you have at least one [params.versions] set.
101+
version_menu = "Releases"
102+
103+
# Flag used in the "version-banner" partial to decide whether to display a
104+
# banner on every page indicating that this is an archived version of the docs.
105+
# Set this flag to "true" if you want to display the banner.
106+
archived_version = false
107+
108+
# The version number for the version of the docs represented in this doc set.
109+
# Used in the "version-banner" partial to display a version number for the
110+
# current doc set.
111+
version = "1.0"
112+
113+
# A link to latest version of the docs. Used in the "version-banner" partial to
114+
# point people to the main doc site.
115+
url_latest_version = "https://protobuf.dev"
116+
117+
# Repository configuration (URLs for in-page links to opening issues and suggesting changes)
118+
github_repo = "https://github.com/protocolbuffers/protocolbuffers.github.io"
119+
# An optional link to a related project repo. For example, the sibling repository where your product code lives.
120+
github_project_repo = "https://github.com/protocolbuffers/protobuf"
121+
122+
# Specify a value here if your content directory is not in your repo's root directory
123+
github_subdir = "/docs"
124+
125+
# Uncomment this if you have a newer GitHub repo with "main" as the default branch,
126+
# or specify a new value if you want to reference another branch in your GitHub links
127+
# github_branch= "main"
128+
129+
# Google Custom Search Engine ID. Remove or comment out to disable search.
130+
gcs_engine_id = "d72aa9b2712488cc3"
131+
132+
# Enable Algolia DocSearch
133+
algolia_docsearch = false
134+
135+
# Enable Lunr.js offline search
136+
offlineSearch = false
137+
138+
# Enable syntax highlighting and copy buttons on code blocks with Prism
139+
prism_syntax_highlighting = false
140+
141+
# User interface configuration
142+
[params.ui]
143+
# Set to true to disable breadcrumb navigation.
144+
breadcrumb_disable = false
145+
# Set to true to disable the About link in the site footer
146+
footer_about_disable = false
147+
# Set to false if you don't want to display a logo (/assets/icons/logo.svg) in the top navbar
148+
navbar_logo = true
149+
# Set to true if you don't want the top navbar to be translucent when over a `block/cover`, like on the homepage.
150+
navbar_translucent_over_cover_disable = false
151+
# Enable to show the side bar menu in its compact state.
152+
sidebar_menu_compact = false
153+
# Set to true to hide the sidebar search box (the top nav search box will still be displayed if search is enabled)
154+
sidebar_search_disable = false
155+
156+
# ui.sidebar_menu_compact = true
157+
ui.ul_show = 2
158+
ui.sidebar_menu_foldable = true
159+
160+
161+
# Adds a H2 section titled "Feedback" to the bottom of each doc. The responses are sent to Google Analytics as events.
162+
# This feature depends on [services.googleAnalytics] and will be disabled if "services.googleAnalytics.id" is not set.
163+
# If you want this feature, but occasionally need to remove the "Feedback" section from a single page,
164+
# add "hide_feedback: true" to the page's front matter.
165+
[params.ui.feedback]
166+
enable = true
167+
# The responses that the user sees after clicking "yes" (the page was helpful) or "no" (the page was not helpful).
168+
yes = 'Glad to hear it! Please <a href="https://github.com/USERNAME/REPOSITORY/issues/new">tell us how we can improve</a>.'
169+
no = 'Sorry to hear that. Please <a href="https://github.com/USERNAME/REPOSITORY/issues/new">tell us how we can improve</a>.'
170+
171+
# Adds a reading time to the top of each doc.
172+
# If you want this feature, but occasionally need to remove the Reading time from a single page,
173+
# add "hide_readingtime: true" to the page's front matter
174+
[params.ui.readingtime]
175+
enable = false
176+
177+
[params.links]
178+
# End user relevant links. These will show up on left side of footer and in the community page if you have one.
179+
[[params.links.user]]
180+
name = "Stack Overflow"
181+
url = "https://stackoverflow.com/questions/tagged/protocol-buffers"
182+
icon = "fab fa-stack-overflow"
183+
desc = "Practical questions and curated answers"
184+
# Developer relevant links. These will show up on right side of footer and in the community page if you have one.
185+
[[params.links.developer]]
186+
name = "GitHub"
187+
url = "https://github.com/protocolbuffers/protobuf"
188+
icon = "fab fa-github"
189+
desc = "Source code, issues, and other details are stored here."
190+
[[params.links.developer]]
191+
name = "Developer mailing list"
192+
url = "https://groups.google.com/g/protobuf"
193+
icon = "fa fa-envelope"
194+
desc = "Discuss development issues around the project"

content/_index.md

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
---
2+
title: "Protocol Buffers"
3+
weight: 5
4+
toc_hide: true
5+
linkTitle: "Protocol Buffers"
6+
no_list: "true"
7+
type: docs
8+
description: "Protocol Buffers are a language-neutral, platform-neutral extensible mechanism for serializing structured data."
9+
---
10+
11+
12+
<!--* css: "//depot/includes/suppress-nav.css" *-->
13+
14+
<style>
15+
.row .highlight {
16+
margin-top: 2rem;
17+
margin-right: 0;
18+
margin-bottom: 0;
19+
margin-left: 0;
20+
padding: 0;
21+
}
22+
</style>
23+
24+
<div class="row">
25+
<div class="col-md">
26+
27+
```proto
28+
message Person {
29+
optional string name = 1;
30+
optional int32 id = 2;
31+
optional string email = 3;
32+
}
33+
```
34+
35+
<p class="caption">A proto definition.</>
36+
</div>
37+
<div class="col-md">
38+
39+
```proto
40+
Person john = Person.newBuilder()
41+
.setId(1234)
42+
.setName("John Doe")
43+
.setEmail("[email protected]")
44+
.build();
45+
output = new FileOutputStream(args[0]);
46+
john.writeTo(output);
47+
48+
```
49+
50+
<p class="caption">Using a generated class to persist data.</p>
51+
</div>
52+
<div class="col-md">
53+
54+
```proto
55+
Person john;
56+
fstream input(argv[1],
57+
ios::in | ios::binary);
58+
john.ParseFromIstream(&input);
59+
id = john.id();
60+
name = john.name();
61+
email = john.email();
62+
63+
```
64+
65+
<p class="caption">Using a generated class to parse persisted data.</p>
66+
</div>
67+
</div>
68+
<div class="row">
69+
<div class="col-md">
70+
71+
## What Are Protocol Buffers?
72+
73+
Protocol buffers are Google's language-neutral, platform-neutral, extensible
74+
mechanism for serializing structured data – think XML, but smaller, faster, and
75+
simpler. You define how you want your data to be structured once, then you can
76+
use special generated source code to easily write and read your structured data
77+
to and from a variety of data streams and using a variety of languages.
78+
79+
</div>
80+
<div class="col-md">
81+
82+
## Pick Your Favorite Language
83+
84+
Protocol buffers currently support generated code in Java, Python, Objective-C,
85+
and C++. With our new proto3 language version, you can also work with Kotlin,
86+
Dart, Go, Ruby, PHP, and C#, with more languages to come.
87+
88+
</div>
89+
<div class="col-md">
90+
91+
## How Do I Start?
92+
93+
<ol>
94+
95+
<li>
96+
<a href="https://github.com/protocolbuffers/protobuf#protocol-compiler-installation">Download
97+
and install</a> the protocol buffer compiler.
98+
</li>
99+
100+
<li>
101+
Read the
102+
<a href="/overview">overview</a>.
103+
</li>
104+
<li>
105+
Try the <a href="/getting-started">tutorial</a> for your
106+
chosen language.
107+
</li>
108+
</ol>
109+
110+
</div>
111+
</div>

0 commit comments

Comments
 (0)