add more guides

This commit is contained in:
sneedgroup-holder 2024-11-04 15:50:31 +00:00
parent 61270185e4
commit be35b739b3
8 changed files with 250 additions and 0 deletions

View file

@ -0,0 +1,36 @@
# Getting Started with Ollama: Running Large Language Models Locally
Ollama is a tool that allows you to run powerful large language models (LLMs) on your own computer. This guide will walk you through the steps of downloading, installing, and using Ollama to interact with LLMs.
## Guide
1. Check Your GPU (Optional):
Ollama can leverage your computer's graphics processing unit (GPU) for faster performance.
During installation, Ollama will automatically detect your GPU.
Make sure you have the latest drivers installed for your NVIDIA or AMD GPU for optimal performance.
2. Download and Install Ollama:
Head over to the official Ollama website: https://ollama.com/
Use the installer for your operating system (Mac, Windows, or Linux).
3. Download a Large Language Model:
Ollama supports various open-source LLMs. You can browse available models on the Ollama blog: https://ollama.com/models
Use the ollama pull command followed by the model name to download an LLM. For example: ```ollama pull llama3```
4. Run the LLM:
Start Ollama using the ollama run command followed by the model name. For instance: ```ollama run llama3```
This will launch the Ollama REPL (Read-Eval-Print Loop) where you can interact with the LLM.
5. Interact with the LLM:
Type your prompts and questions in the Ollama REPL.
The LLM will respond based on its understanding of your input.
You can experiment with different prompts and see how the LLM generates text, translates languages, writes different kinds of creative content, and answers your questions in an informative way.
## Additional Resources:
Ollama Documentation: https://github.com/ollama/ollama offers detailed guides on installation, using specific LLM features, and integrating Ollama with Python and other tools.

47
guides/git/github-git.gmi Normal file
View file

@ -0,0 +1,47 @@
## Using Git with GitHub (Passwordless Authentication)
Since GitHub no longer supports password authentication for Git, here's how to connect using SSH keys:
1. Generate SSH Key Pair
Open your terminal and run the following command, replacing `<your_email>` with your actual email address:
```ssh-keygen -t ed25519 -e -m "<your_email>"```
This will prompt you for a passphrase (optional) and save the key pair to your local machine (usually `~/.ssh/`).
2. Add Public Key to GitHub
* Go to your GitHub account settings.
* Navigate to the "SSH and GPG keys" section.
* Click "New SSH key" and provide a title for your key.
* Copy the contents of the file `~/.ssh/id_rsa.pub` (public key) and paste it into the key field on GitHub.
* Click "Add SSH key".
3. Verify Connection
In your terminal, run the following command to test the connection:
```ssh -T git@github.com```
If successful, you should see a welcome message from GitHub.
4. Cloning a Repository
Now you can use the `git clone` command followed by the SSH URL of the repository to clone it locally. You'll find the SSH URL on the repository homepage on GitHub. The URL will look something like `git@github.com:<username>/<repository_name>.git`.
Example:
```git clone git@github.com/<username>/<repository_name>.git```
Subsequent Pushes
Once you've made changes and added/committed them, you can push them to your remote repository on GitHub using:
```git push origin <branch_name>```
Notes:
* Replace `<username>`, `<repository_name>`, and `<branch_name>` with your actual details.
* This guide covers basic usage. Refer to the official [Git documentation](https://git-scm.com/) for more advanced commands.

View file

@ -1,8 +1,19 @@
# Tree of files in guides/
## ai
=> ai/ollama-basics.gmi ollama-basics.gmi
=> favicon.txt favicon.txt
## git
=> git/github-git.gmi github-git.gmi
=> index.gmi index.gmi
## linux
=> linux/arch-install.gmi arch-install.gmi
=> linux/install-docker-ubuntu.gmi install-docker-ubuntu.gmi
=> linux/symbolic-links.gmi symbolic-links.gmi
## macos
=> macos/macos-install-guide.gmi macos-install-guide.gmi
## nginx
=> nginx/file-list-mode.gmi file-list-mode.gmi
=> nginx/where-is-stuff.gmi where-is-stuff.gmi
## windows
=> windows/upgrade-utility.gmi upgrade-utility.gmi

View file

@ -0,0 +1,27 @@
# Installing docker in Ubuntu...
## Get the repo
sudo apt-get update
sudo apt-get install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
## Add the repository to Apt sources:
```
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
```
***NOTE: If you use an Ubuntu derivative distro, such as Linux Mint, you may need to use UBUNTU_CODENAME instead of VERSION_CODENAME.***
## Get the latest docker.
```
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin```
```

View file

@ -0,0 +1,91 @@
# Guide to symbolic links
Creating symbolic links in Linux using the terminal is a straightforward process. Symbolic links, also known as symlinks or soft links, are references to another file or directory in the filesystem. They act like shortcuts or pointers to the target file or directory.
Here's a step-by-step guide on how to create symbolic links in the Linux terminal.
## Basic Syntax
The basic syntax for creating a symbolic link in Linux is:
```
ln -s target_file_or_directory link_name
```
## Steps to Create a Symbolic Link
* Open a Terminal:
First, open your terminal emulator. You can find it in your applications menu or use a keyboard shortcut like Ctrl + Alt + T on many Linux distributions.
Navigate to the Directory:
Use the cd command to navigate to the directory where you want to create the symbolic link. For example:
```
cd /path/to/directory
```
* Create the Symbolic Link:
Use the ln command with the -s option to create a symbolic link. Replace target_file_or_directory with the path to the file or directory you want to link to, and link_name with the desired name for the symbolic link.
```
ln -s /path/to/target_file_or_directory link_name
```
For example, to create a symbolic link named docs pointing to a directory /home/user/documents, you would use:
```
ln -s /home/user/documents docs
```
## Example Scenarios
* Linking Files:
To create a symbolic link for a file example.txt located in /home/user and name the link shortcut.txt in the current directory:
```
ln -s /home/user/example.txt shortcut.txt
```
* Linking Directories:
To create a symbolic link for a directory /mnt/data named data_link in the current directory:
```
ln -s /mnt/data data_link
```
### Additional Options
* Force Overwrite (-f): Use -f option with ln to force the creation of a symbolic link if a link with the same name already exists.
```
ln -sf /path/to/target_file_or_directory link_name
```
* Verbose Mode (-v): Use -v option to display the symbolic link creation process.
```
ln -sv /path/to/target_file_or_directory link_name
```
* Checking Symbolic Links
To verify symbolic links in a directory, you can use the ls command with the -l option, which shows detailed information about files and directories including symbolic links:
```
ls -l
```
Symbolic links are indicated by an l at the start of the permissions field, followed by the link name and the target it points to.
* Removing Symbolic Links
To remove a symbolic link, use the rm command followed by the link name:
```
rm link_name
```
## Conclusion
Creating symbolic links in Linux is useful for referencing files and directories across the filesystem without needing to duplicate them. They are versatile tools for organizing and accessing data efficiently from different locations. By following these steps and examples, you can effectively create and manage symbolic links in your Linux terminal.

View file

@ -0,0 +1,11 @@
# Enabling File List Mode NGINX
If there isn't an `index.html` file in a specific directory you want to view, accessing that URL path will result in a "404 Not Found" error. However, Nginx includes an autoindex module that can automatically generate a directory listing. Adding autoindex to your Nginx configuration is straightforward. Simply add it to the `location` block in your Nginx configuration file like this:
```
location /somedirectory/ {
autoindex on;
}
```
Once you've made this change, restart your Nginx server using `sudo service nginx restart`. Now, instead of displaying a "404" error, the web server will show a directory listing similar to the one described earlier for the directory/directories defined in your `location` block.

View file

@ -0,0 +1,12 @@
# Where is stuff in NGINX
## The location of the main Nginx configuration file depends on how Nginx was installed:
* On many Linux distributions, it can be found at "/etc/nginx/nginx.conf".
* Alternatively, it might be located at "/usr/local/nginx/conf/nginx.conf" or "/usr/local/etc/nginx/nginx.conf" if not found in the default location.
## The location of available sites:
* Typically stored in "/etc/nginx/sites-available".
## The location of enabled sites:
* Usually stored in "/etc/nginx/sites-enabled".
* Enabled sites are symbolic links to files located in the "sites-available" directory mentioned above.

View file

@ -0,0 +1,15 @@
# Using My Windows 11 Upgrade Utility
This upgrade utility will let you install Windows 11 on an unsupported PC.
* Download Windows 11 ISO
=> https://github.com/the-spellman/win11upgradeutil/blob/main/upgrade.bat Download the script
* Mount the Windows 11 ISO
* Check the mounted drive ISO's leter
* Open the script
* Enter the DRIVE LETTER ONLY, no colon, whitespace, or extra path details!
* Click yes at the admin prompt
* The setup will now be spoofed to be the Server Edition setup, thus bypassing TPM and CPU checks.
**NOTE: Your Windows 10 edition should be preserved if it's Pro or Home. I have not tested it with Enterprise or Server**