Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
docs-action committed Nov 14, 2023
1 parent 6e3c43e commit 216a1e7
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 37 deletions.
Binary file added assets/img/quickstart/quickstart-repo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion assets/js/search-data.json
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@
},"71": {
"doc": "3️⃣ Create a branch",
"title": "What about the data in main?",
"content": "So we’ve changed the data in our denmark-lakes branch, deleting swathes of the dataset. What’s this done to our original data in the main branch? Absolutely nothing! See for yourself by running the same query as above, but against the main branch: . SELECT country, COUNT(*) FROM READ_PARQUET('lakefs://quickstart/main/lakes.parquet') GROUP BY country ORDER BY COUNT(*) DESC LIMIT 5; . In the next step we’ll see how to merge our branch back into main. ",
"content": "So we’ve changed the data in our denmark-lakes branch, deleting swathes of the dataset. What’s this done to our original data in the main branch? Absolutely nothing! See for yourself by running the same query as above, but against the main branch: . SELECT country, COUNT(*) FROM READ_PARQUET('lakefs://quickstart/main/lakes.parquet') GROUP BY country ORDER BY COUNT(*) DESC LIMIT 5; . In the next step we’ll see how to commit our changes and merge our branch back into main. ",
"url": "/quickstart/branch.html#what-about-the-data-in-main",

"relUrl": "/quickstart/branch.html#what-about-the-data-in-main"
Expand Down
70 changes: 35 additions & 35 deletions quickstart/actions-and-hooks.html
Original file line number Diff line number Diff line change
Expand Up @@ -561,41 +561,41 @@ <h2 id="configuring-the-action">
<li>
<p>Open up your favorite text editor (or emacs), and paste the following YAML:</p>

<div class="language-yaml highlighter-rouge"><div class="highlight"><pre class="highlight"><code> <span class="na">name</span><span class="pi">:</span> <span class="s">Check Commit Message and Metadata</span>
<span class="na">on</span><span class="pi">:</span>
<span class="na">pre-commit</span><span class="pi">:</span>
<span class="na">branches</span><span class="pi">:</span>
<span class="pi">-</span> <span class="s">etl**</span>
<span class="na">hooks</span><span class="pi">:</span>
<span class="pi">-</span> <span class="na">id</span><span class="pi">:</span> <span class="s">check_metadata</span>
<span class="s">type</span><span class="pi">:</span> <span class="s">lua</span>
<span class="s">properties</span><span class="pi">:</span>
<span class="na">script</span><span class="pi">:</span> <span class="pi">|</span>
<span class="s">commit_message=action.commit.message</span>
<span class="s">if commit_message and #commit_message&gt;0 then</span>
<span class="s">print("✅ The commit message exists and is not empty: " .. commit_message)</span>
<span class="s">else</span>
<span class="s">error("\n\n❌ A commit message must be provided")</span>
<span class="s">end</span>

<span class="s">job_name=action.commit.metadata["job_name"]</span>
<span class="s">if job_name == nil then</span>
<span class="s">error("\n❌ Commit metadata must include job_name")</span>
<span class="s">else</span>
<span class="s">print("✅ Commit metadata includes job_name: " .. job_name)</span>
<span class="s">end</span>

<span class="s">version=action.commit.metadata["version"]</span>
<span class="s">if version == nil then</span>
<span class="s">error("\n❌ Commit metadata must include version")</span>
<span class="s">else</span>
<span class="s">print("✅ Commit metadata includes version: " .. version)</span>
<span class="s">if tonumber(version) then</span>
<span class="s">print("✅ Commit metadata version is numeric")</span>
<span class="s">else</span>
<span class="s">error("\n❌ Version metadata must be numeric: " .. version)</span>
<span class="s">end</span>
<span class="s">end</span>
<div class="language-yaml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="na">name</span><span class="pi">:</span> <span class="s">Check Commit Message and Metadata</span>
<span class="na">on</span><span class="pi">:</span>
<span class="na">pre-commit</span><span class="pi">:</span>
<span class="na">branches</span><span class="pi">:</span>
<span class="pi">-</span> <span class="s">etl**</span>
<span class="na">hooks</span><span class="pi">:</span>
<span class="pi">-</span> <span class="na">id</span><span class="pi">:</span> <span class="s">check_metadata</span>
<span class="na">type</span><span class="pi">:</span> <span class="s">lua</span>
<span class="na">properties</span><span class="pi">:</span>
<span class="na">script</span><span class="pi">:</span> <span class="pi">|</span>
<span class="s">commit_message=action.commit.message</span>
<span class="s">if commit_message and #commit_message&gt;0 then</span>
<span class="s">print("✅ The commit message exists and is not empty: " .. commit_message)</span>
<span class="s">else</span>
<span class="s">error("\n\n❌ A commit message must be provided")</span>
<span class="s">end</span>
<span class="s">job_name=action.commit.metadata["job_name"]</span>
<span class="s">if job_name == nil then</span>
<span class="s">error("\n❌ Commit metadata must include job_name")</span>
<span class="s">else</span>
<span class="s">print("✅ Commit metadata includes job_name: " .. job_name)</span>
<span class="s">end</span>
<span class="s">version=action.commit.metadata["version"]</span>
<span class="s">if version == nil then</span>
<span class="s">error("\n❌ Commit metadata must include version")</span>
<span class="s">else</span>
<span class="s">print("✅ Commit metadata includes version: " .. version)</span>
<span class="s">if tonumber(version) then</span>
<span class="s">print("✅ Commit metadata version is numeric")</span>
<span class="s">else</span>
<span class="s">error("\n❌ Version metadata must be numeric: " .. version)</span>
<span class="s">end</span>
<span class="s">end</span>
</code></pre></div> </div>
</li>
<li>
Expand Down
2 changes: 1 addition & 1 deletion quickstart/branch.html
Original file line number Diff line number Diff line change
Expand Up @@ -666,7 +666,7 @@ <h2 id="what-about-the-data-in-main">
</code></pre></div></div>
<p><img src="/assets/img/quickstart/duckdb-main-02.png" alt="The lakeFS object browser showing DuckDB querying lakes.parquet on the main branch. The results are the same as they were before we made the changes to the denmark-lakes branch, which is as expected." class="quickstart" /></p>

<p>In the next step we’ll see how to merge our branch back into main.</p>
<p>In the next step we’ll see how to commit our changes and merge our branch back into main.</p>



Expand Down

0 comments on commit 216a1e7

Please sign in to comment.