Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
mug896 committed Oct 17, 2024
0 parents commit ebeb557
Show file tree
Hide file tree
Showing 254 changed files with 161,327 additions and 0 deletions.
2,253 changes: 2,253 additions & 0 deletions arrays.html

Large diffs are not rendered by default.

1,785 changes: 1,785 additions & 0 deletions basics.html

Large diffs are not rendered by default.

1,898 changes: 1,898 additions & 0 deletions buffering.html

Large diffs are not rendered by default.

1,423 changes: 1,423 additions & 0 deletions bug_reports.html

Large diffs are not rendered by default.

2,394 changes: 2,394 additions & 0 deletions builtin_commands.html

Large diffs are not rendered by default.

1,535 changes: 1,535 additions & 0 deletions closing.html

Large diffs are not rendered by default.

2,125 changes: 2,125 additions & 0 deletions colors_and_prompt.html

Large diffs are not rendered by default.

1,740 changes: 1,740 additions & 0 deletions command_aliases.html

Large diffs are not rendered by default.

2,589 changes: 2,589 additions & 0 deletions command_completion.html

Large diffs are not rendered by default.

1,948 changes: 1,948 additions & 0 deletions command_history.html

Large diffs are not rendered by default.

1,491 changes: 1,491 additions & 0 deletions command_line_options.html

Large diffs are not rendered by default.

1,929 changes: 1,929 additions & 0 deletions commands.html

Large diffs are not rendered by default.

2,280 changes: 2,280 additions & 0 deletions compound_commands.html

Large diffs are not rendered by default.

Binary file added cover_awk.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cover_bash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cover_macro.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cover_make.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added cover_sed.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2,184 changes: 2,184 additions & 0 deletions debugging.html

Large diffs are not rendered by default.

1,591 changes: 1,591 additions & 0 deletions escape_sequences.html

Large diffs are not rendered by default.

1,771 changes: 1,771 additions & 0 deletions etc.html

Large diffs are not rendered by default.

1,718 changes: 1,718 additions & 0 deletions eval.html

Large diffs are not rendered by default.

1,667 changes: 1,667 additions & 0 deletions exit_status.html

Large diffs are not rendered by default.

1,604 changes: 1,604 additions & 0 deletions exp_and_sub/arithmetic_expansion.html

Large diffs are not rendered by default.

1,660 changes: 1,660 additions & 0 deletions exp_and_sub/brace_expansion.html

Large diffs are not rendered by default.

1,672 changes: 1,672 additions & 0 deletions exp_and_sub/command_substitution.html

Large diffs are not rendered by default.

1,743 changes: 1,743 additions & 0 deletions exp_and_sub/filename_expansion.html

Large diffs are not rendered by default.

Binary file added exp_and_sub/images/command_substitution.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added exp_and_sub/images/parameter_expansion.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added exp_and_sub/images/proc_sub_exec.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added exp_and_sub/images/proc_sub_fd1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added exp_and_sub/images/proc_sub_fd2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added exp_and_sub/images/process_substitution.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2,209 changes: 2,209 additions & 0 deletions exp_and_sub/parameter_expansion.html

Large diffs are not rendered by default.

1,848 changes: 1,848 additions & 0 deletions exp_and_sub/process_substitution.html

Large diffs are not rendered by default.

1,456 changes: 1,456 additions & 0 deletions exp_and_sub/tilde_expansion.html

Large diffs are not rendered by default.

1,745 changes: 1,745 additions & 0 deletions exp_and_sub/word_splitting.html

Large diffs are not rendered by default.

1,474 changes: 1,474 additions & 0 deletions expansions_and_substitutions.html

Large diffs are not rendered by default.

1,496 changes: 1,496 additions & 0 deletions expr.html

Large diffs are not rendered by default.

2,312 changes: 2,312 additions & 0 deletions file_descriptors.html

Large diffs are not rendered by default.

1,882 changes: 1,882 additions & 0 deletions find.html

Large diffs are not rendered by default.

1,993 changes: 1,993 additions & 0 deletions functions.html

Large diffs are not rendered by default.

2,419 changes: 2,419 additions & 0 deletions getopts.html

Large diffs are not rendered by default.

25,001 changes: 25,001 additions & 0 deletions gitbook/app.js

Large diffs are not rendered by default.

Binary file added gitbook/fonts/fontawesome/FontAwesome.otf
Binary file not shown.
Binary file added gitbook/fonts/fontawesome/fontawesome-webfont.eot
Binary file not shown.
504 changes: 504 additions & 0 deletions gitbook/fonts/fontawesome/fontawesome-webfont.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added gitbook/images/favicon.ico
Binary file not shown.
151 changes: 151 additions & 0 deletions gitbook/plugins/gitbook-plugin-fontsettings/buttons.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
require(["gitbook", "lodash", "jQuery"], function(gitbook, _, $) {
var fontState;

var THEMES = {
"white": 0,
"sepia": 1,
"night": 2
};

var FAMILY = {
"serif": 0,
"sans": 1
};

// Save current font settings
function saveFontSettings() {
gitbook.storage.set("fontState", fontState);
update();
}

// Increase font size
function enlargeFontSize(e) {
e.preventDefault();
if (fontState.size >= 4) return;

fontState.size++;
saveFontSettings();
};

// Decrease font size
function reduceFontSize(e) {
e.preventDefault();
if (fontState.size <= 0) return;

fontState.size--;
saveFontSettings();
};

// Change font family
function changeFontFamily(index, e) {
e.preventDefault();

fontState.family = index;
saveFontSettings();
};

// Change type of color
function changeColorTheme(index, e) {
e.preventDefault();

var $book = $(".book");

if (fontState.theme !== 0)
$book.removeClass("color-theme-"+fontState.theme);

fontState.theme = index;
if (fontState.theme !== 0)
$book.addClass("color-theme-"+fontState.theme);

saveFontSettings();
};

function update() {
var $book = gitbook.state.$book;

$(".font-settings .font-family-list li").removeClass("active");
$(".font-settings .font-family-list li:nth-child("+(fontState.family+1)+")").addClass("active");

$book[0].className = $book[0].className.replace(/\bfont-\S+/g, '');
$book.addClass("font-size-"+fontState.size);
$book.addClass("font-family-"+fontState.family);

if(fontState.theme !== 0) {
$book[0].className = $book[0].className.replace(/\bcolor-theme-\S+/g, '');
$book.addClass("color-theme-"+fontState.theme);
}
};

function init(config) {
var $bookBody, $book;

//Find DOM elements.
$book = gitbook.state.$book;
$bookBody = $book.find(".book-body");

// Instantiate font state object
fontState = gitbook.storage.get("fontState", {
size: config.size || 2,
family: FAMILY[config.family || "sans"],
theme: THEMES[config.theme || "white"]
});

update();
};


gitbook.events.bind("start", function(e, config) {
var opts = config.fontsettings;

// Create buttons in toolbar
gitbook.toolbar.createButton({
icon: 'fa fa-font',
label: 'Font Settings',
className: 'font-settings',
dropdown: [
[
{
text: 'A',
className: 'font-reduce',
onClick: reduceFontSize
},
{
text: 'A',
className: 'font-enlarge',
onClick: enlargeFontSize
}
],
[
{
text: 'Serif',
onClick: _.partial(changeFontFamily, 0)
},
{
text: 'Sans',
onClick: _.partial(changeFontFamily, 1)
}
],
[
{
text: 'White',
onClick: _.partial(changeColorTheme, 0)
},
{
text: 'Sepia',
onClick: _.partial(changeColorTheme, 1)
},
{
text: 'Night',
onClick: _.partial(changeColorTheme, 2)
}
]
]
});


// Init current settings
init(opts);
});
});


Loading

0 comments on commit ebeb557

Please sign in to comment.