Skip to content

Commit

Permalink
Merge branch 'book-fa' of bundle-fa/fa.bundle into hugo
Browse files Browse the repository at this point in the history
  • Loading branch information
dscho committed Nov 18, 2023
2 parents a246ddf + 31d73ac commit 5c43b48
Show file tree
Hide file tree
Showing 688 changed files with 2,321 additions and 458 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ <h4 id="_enforcing_commit_message_format">Enforcing a Specific Commit-Message Fo
<div class="paragraph">
<p>You have to figure out how to get the commit message from each of these commits to test.
To get the raw commit data, you can use another plumbing command called <code>git cat-file</code>.
We’ll go over all these plumbing commands in detail in <a href="ch00/ch10-git-internals">Git Internals</a>; but for now, here’s what that command gives you:</p>
We’ll go over all these plumbing commands in detail in <a href="{{< relurl "book/fa/v2/ch00/ch10-git-internals" >}}">Git Internals</a>; but for now, here’s what that command gives you:</p>
</div>
<div class="listingblock">
<div class="content">
Expand Down Expand Up @@ -212,7 +212,7 @@ <h4 id="_enforcing_a_user_based_acl_system">Enforcing a User-Based ACL System</h
<p>Now that you have the permissions sorted out, you need to determine what paths the commits being pushed have modified, so you can make sure the user who’s pushing has access to all of them.</p>
</div>
<div class="paragraph">
<p>You can pretty easily see what files have been modified in a single commit with the <code>--name-only</code> option to the <code>git log</code> command (mentioned briefly in <a href="ch00/ch02-git-basics-chapter">مقدمات گیت</a>):</p>
<p>You can pretty easily see what files have been modified in a single commit with the <code>--name-only</code> option to the <code>git log</code> command (mentioned briefly in <a href="{{< relurl "book/fa/v2/ch00/ch02-git-basics-chapter" >}}">مقدمات گیت</a>):</p>
</div>
<div class="listingblock">
<div class="content">
Expand Down Expand Up @@ -502,7 +502,7 @@ <h3 id="_client_side_hooks_2">Client-Side Hooks</h3>
</div>
</div>
<div class="paragraph">
<p>This script uses a syntax that wasn’t covered in <a href="ch00/_revision_selection">Revision Selection</a>.
<p>This script uses a syntax that wasn’t covered in <a href="{{< relurl "book/fa/v2/ch00/_revision_selection" >}}">Revision Selection</a>.
You get a list of commits that have already been pushed up by running this:</p>
</div>
<div class="listingblock">
Expand Down
6 changes: 3 additions & 3 deletions content/book/fa/v2/Customizing-Git-Git-Attributes.html
Original file line number Diff line number Diff line change
Expand Up @@ -238,18 +238,18 @@ <h3 id="_keyword_expansion">Keyword Expansion</h3>
<div class="paragraph">
<p>It turns out that you can write your own filters for doing substitutions in files on commit/checkout.
These are called “clean” and “smudge” filters.
In the <code>.gitattributes</code> file, you can set a filter for particular paths and then set up scripts that will process files just before they’re checked out (“smudge”, see <a href="ch00/filters_a">The “smudge” filter is run on checkout.</a>) and just before they’re staged (“clean”, see <a href="ch00/filters_b">The “clean” filter is run when files are staged.</a>).
In the <code>.gitattributes</code> file, you can set a filter for particular paths and then set up scripts that will process files just before they’re checked out (“smudge”, see <a href="{{< relurl "book/fa/v2/ch00/filters_a" >}}">The “smudge” filter is run on checkout.</a>) and just before they’re staged (“clean”, see <a href="{{< relurl "book/fa/v2/ch00/filters_b" >}}">The “clean” filter is run when files are staged.</a>).
These filters can be set to do all sorts of fun things.</p>
</div>
<div id="filters_a" class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/smudge.png" >}}" alt="The ``smudge'' filter is run on checkout.">
<img src="{{< relurl "book/fa/v2/images/smudge.png" >}}" alt="The ``smudge'' filter is run on checkout.">
</div>
<div class="title">نمودار 144. The “smudge” filter is run on checkout.</div>
</div>
<div id="filters_b" class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/clean.png" >}}" alt="The ``clean'' filter is run when files are staged.">
<img src="{{< relurl "book/fa/v2/images/clean.png" >}}" alt="The ``clean'' filter is run when files are staged.">
</div>
<div class="title">نمودار 145. The “clean” filter is run when files are staged.</div>
</div>
Expand Down
10 changes: 5 additions & 5 deletions content/book/fa/v2/Customizing-Git-Git-Configuration.html
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<h2 id="_git_config">Git Configuration</h2>
<div class="paragraph">
<p>
As you read briefly in <a href="ch00/ch01-getting-started">شروع به کار</a>, you can specify Git configuration settings with the <code>git config</code> command.
As you read briefly in <a href="{{< relurl "book/fa/v2/ch00/ch01-getting-started" >}}">شروع به کار</a>, you can specify Git configuration settings with the <code>git config</code> command.
One of the first things you did was set up your name and email address:</p>
</div>
<div class="listingblock">
Expand Down Expand Up @@ -180,7 +180,7 @@ <h4 id="_core_pager"><code>core.pager</code></h4>
<h4 id="_user_signingkey"><code>user.signingkey</code></h4>
<div class="paragraph">
<p>
If you’re making signed annotated tags (as discussed in <a href="ch00/_signing">Signing Your Work</a>), setting your GPG signing key as a configuration setting makes things easier.
If you’re making signed annotated tags (as discussed in <a href="{{< relurl "book/fa/v2/ch00/_signing" >}}">Signing Your Work</a>), setting your GPG signing key as a configuration setting makes things easier.
Set your key ID like so:</p>
</div>
<div class="listingblock">
Expand All @@ -201,7 +201,7 @@ <h4 id="_user_signingkey"><code>user.signingkey</code></h4>
<h4 id="_core_excludesfile"><code>core.excludesfile</code></h4>
<div class="paragraph">
<p>
You can put patterns in your project’s <code>.gitignore</code> file to have Git not see them as untracked files or try to stage them when you run <code>git add</code> on them, as discussed in <a href="ch00/_ignoring">نادیده گرفتن فایل‌ها</a>.</p>
You can put patterns in your project’s <code>.gitignore</code> file to have Git not see them as untracked files or try to stage them when you run <code>git add</code> on them, as discussed in <a href="{{< relurl "book/fa/v2/ch00/_ignoring" >}}">نادیده گرفتن فایل‌ها</a>.</p>
</div>
<div class="paragraph">
<p>But sometimes you want to ignore certain files for all repositories that you work with.
Expand Down Expand Up @@ -407,7 +407,7 @@ <h3 id="_external_merge_tools">External Merge and Diff Tools</h3>
</div>
<div class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/p4merge.png" >}}" alt="P4Merge.">
<img src="{{< relurl "book/fa/v2/images/p4merge.png" >}}" alt="P4Merge.">
</div>
<div class="title">نمودار 143. P4Merge.</div>
</div>
Expand Down Expand Up @@ -631,7 +631,7 @@ <h4 id="_receive_denydeletes"><code>receive.denyDeletes</code></h4>
<div class="paragraph">
<p>This denies any deletion of branches or tags — no user can do it.
To remove remote branches, you must remove the ref files from the server manually.
There are also more interesting ways to do this on a per-user basis via ACLs, as you’ll learn in <a href="ch00/_an_example_git_enforced_policy">An Example Git-Enforced Policy</a>.</p>
There are also more interesting ways to do this on a per-user basis via ACLs, as you’ll learn in <a href="{{< relurl "book/fa/v2/ch00/_an_example_git_enforced_policy" >}}">An Example Git-Enforced Policy</a>.</p>
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion content/book/fa/v2/Customizing-Git-Git-Hooks.html
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ <h3 id="_client_side_hooks">Client-Side Hooks</h3>
<td class="content">
<div class="paragraph">
<p>It’s important to note that client-side hooks are <strong>not</strong> copied when you clone a repository.
If your intent with these scripts is to enforce a policy, you’ll probably want to do that on the server side; see the example in <a href="ch00/_an_example_git_enforced_policy">An Example Git-Enforced Policy</a>.</p>
If your intent with these scripts is to enforce a policy, you’ll probably want to do that on the server side; see the example in <a href="{{< relurl "book/fa/v2/ch00/_an_example_git_enforced_policy" >}}">An Example Git-Enforced Policy</a>.</p>
</div>
</td>
</tr>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ <h3 id="_miscellaneous">Miscellaneous</h3>
<div class="paragraph">
<p><strong><code>GIT_ASKPASS</code></strong> is an override for the <code>core.askpass</code> configuration value.
This is the program invoked whenever Git needs to ask the user for credentials, which can expect a text prompt as a command-line argument, and should return the answer on <code>stdout</code>.
(See <a href="ch00/_credential_caching">Credential Storage</a> for more on this subsystem.)</p>
(See <a href="{{< relurl "book/fa/v2/ch00/_credential_caching" >}}">Credential Storage</a> for more on this subsystem.)</p>
</div>
<div class="paragraph">
<p><strong><code>GIT_NAMESPACE</code></strong> controls access to namespaced refs, and is equivalent to the <code>--namespace</code> flag.
Expand Down
6 changes: 3 additions & 3 deletions content/book/fa/v2/Git-Internals-Git-Objects.html
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ <h3 id="_tree_objects">Tree Objects</h3>
</div>
<div class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/data-model-1.png" >}}" alt="Simple version of the Git data model.">
<img src="{{< relurl "book/fa/v2/images/data-model-1.png" >}}" alt="Simple version of the Git data model.">
</div>
<div class="title">نمودار 149. Simple version of the Git data model.</div>
</div>
Expand Down Expand Up @@ -295,7 +295,7 @@ <h3 id="_tree_objects">Tree Objects</h3>
</div>
<div class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/data-model-2.png" >}}" alt="The content structure of your current Git data.">
<img src="{{< relurl "book/fa/v2/images/data-model-2.png" >}}" alt="The content structure of your current Git data.">
</div>
<div class="title">نمودار 150. The content structure of your current Git data.</div>
</div>
Expand Down Expand Up @@ -409,7 +409,7 @@ <h3 id="_git_commit_objects">Commit Objects</h3>
</div>
<div class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/data-model-3.png" >}}" alt="All the reachable objects in your Git directory.">
<img src="{{< relurl "book/fa/v2/images/data-model-3.png" >}}" alt="All the reachable objects in your Git directory.">
</div>
<div class="title">نمودار 151. All the reachable objects in your Git directory.</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions content/book/fa/v2/Git-Internals-Git-References.html
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ <h2 id="_git_refs">Git References</h2>
</div>
<div class="imageblock">
<div class="content">
<img src="{{< relurl "book/en/v2/images/data-model-4.png" >}}" alt="Git directory objects with branch head references included.">
<img src="{{< relurl "book/fa/v2/images/data-model-4.png" >}}" alt="Git directory objects with branch head references included.">
</div>
<div class="title">نمودار 152. Git directory objects with branch head references included.</div>
</div>
Expand Down Expand Up @@ -167,7 +167,7 @@ <h3 id="_tags">Tags</h3>
It’s like a branch reference, but it never moves — it always points to the same commit but gives it a friendlier name.</p>
</div>
<div class="paragraph">
<p>As discussed in <a href="ch00/ch02-git-basics-chapter">مقدمات گیت</a>, there are two types of tags: annotated and lightweight.
<p>As discussed in <a href="{{< relurl "book/fa/v2/ch00/ch02-git-basics-chapter" >}}">مقدمات گیت</a>, there are two types of tags: annotated and lightweight.
You can make a lightweight tag by running something like this:</p>
</div>
<div class="listingblock">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ <h3 id="_data_recovery">Data Recovery</h3>
<p>Often, the quickest way is to use a tool called <code>git reflog</code>.
As you’re working, Git silently records what your HEAD is every time you change it.
Each time you commit or change branches, the reflog is updated.
The reflog is also updated by the <code>git update-ref</code> command, which is another reason to use it instead of just writing the SHA-1 value to your ref files, as we covered in <a href="ch00/_git_refs">Git References</a>.
The reflog is also updated by the <code>git update-ref</code> command, which is another reason to use it instead of just writing the SHA-1 value to your ref files, as we covered in <a href="{{< relurl "book/fa/v2/ch00/_git_refs" >}}">Git References</a>.
You can see where you’ve been at any time by running <code>git reflog</code>:</p>
</div>
<div class="listingblock">
Expand Down Expand Up @@ -307,7 +307,7 @@ <h3 id="_removing_objects">Removing Objects</h3>
</div>
<div class="paragraph">
<p>The big object is at the bottom: 5MB.
To find out what file it is, you’ll use the <code>rev-list</code> command, which you used briefly in <a href="ch00/_enforcing_commit_message_format">Enforcing a Specific Commit-Message Format</a>.
To find out what file it is, you’ll use the <code>rev-list</code> command, which you used briefly in <a href="{{< relurl "book/fa/v2/ch00/_enforcing_commit_message_format" >}}">Enforcing a Specific Commit-Message Format</a>.
If you pass <code>--objects</code> to <code>rev-list</code>, it lists all the commit SHA-1s and also the blob SHA-1s with the file paths associated with them.
You can use this to find your blob’s name:</p>
</div>
Expand All @@ -330,7 +330,7 @@ <h3 id="_removing_objects">Removing Objects</h3>
</div>
<div class="paragraph">
<p>You must rewrite all the commits downstream from <code>7b30847</code> to fully remove this file from your Git history.
To do so, you use <code>filter-branch</code>, which you used in <a href="ch00/_rewriting_history">Rewriting History</a>:</p>
To do so, you use <code>filter-branch</code>, which you used in <a href="{{< relurl "book/fa/v2/ch00/_rewriting_history" >}}">Rewriting History</a>:</p>
</div>
<div class="listingblock">
<div class="content">
Expand All @@ -342,7 +342,7 @@ <h3 id="_removing_objects">Removing Objects</h3>
</div>
</div>
<div class="paragraph">
<p>The <code>--index-filter</code> option is similar to the <code>--tree-filter</code> option used in <a href="ch00/_rewriting_history">Rewriting History</a>, except that instead of passing a command that modifies files checked out on disk, you’re modifying your staging area or index each time.</p>
<p>The <code>--index-filter</code> option is similar to the <code>--tree-filter</code> option used in <a href="{{< relurl "book/fa/v2/ch00/_rewriting_history" >}}">Rewriting History</a>, except that instead of passing a command that modifies files checked out on disk, you’re modifying your staging area or index each time.</p>
</div>
<div class="paragraph">
<p>Rather than remove a specific file with something like <code>rm file</code>, you have to remove it with <code>git rm --cached</code> – you must remove it from the index, not from disk.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ <h2 id="_plumbing_porcelain">Plumbing and Porcelain</h2>
<p>Depending on your version of Git, you may see some additional content there, but this is a fresh <code>git init</code> repository — it’s what you see by default.
The <code>description</code> file is used only by the GitWeb program, so don’t worry about it.
The <code>config</code> file contains your project-specific configuration options, and the <code>info</code> directory keeps a global exclude file for ignored patterns that you don’t want to track in a <code>.gitignore</code> file.
The <code>hooks</code> directory contains your client- or server-side hook scripts, which are discussed in detail in <a href="ch00/_git_hooks">Git Hooks</a>.</p>
The <code>hooks</code> directory contains your client- or server-side hook scripts, which are discussed in detail in <a href="{{< relurl "book/fa/v2/ch00/_git_hooks" >}}">Git Hooks</a>.</p>
</div>
<div class="paragraph">
<p>This leaves four important entries: the <code>HEAD</code> and (yet to be created) <code>index</code> files, and the <code>objects</code> and <code>refs</code> directories.
Expand Down
2 changes: 1 addition & 1 deletion content/book/fa/v2/Git-Internals-The-Refspec.html
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ <h3 id="_pushing_refspecs">Pushing Refspecs</h3>
<td class="content">
<div class="paragraph">
<p>You cannot use the refspec to fetch from one repository and push to another one.
For an example to do so, refer to <a href="ch00/_fetch_and_push_on_different_repositories">Keep your GitHub public repository up-to-date</a>.</p>
For an example to do so, refer to <a href="{{< relurl "book/fa/v2/ch00/_fetch_and_push_on_different_repositories" >}}">Keep your GitHub public repository up-to-date</a>.</p>
</div>
</td>
</tr>
Expand Down
Loading

0 comments on commit 5c43b48

Please sign in to comment.