Skip to the content.

Verify_ipynb_2_


title: Jupiter Notebook Permalink: /github/pages/untitled-1jpynb —

%%script bash

# Dependency Variables, set to match your project directories

cat <<EOF > /tmp/variables.sh
export project_dir=$HOME/.vscode  # change nighthawk to different name to test your git clone
export project=\$project_dir/avas_2025  # change portfolio_2025 to name of project from git clone
export project_repo="https://github.com/ava-dn/avas_2025.git"  # change to project you created from portfolio_2025 template 
EOF
%%script bash

# Extract saved variables
source /tmp/variables.sh

# Output shown title and value variables
echo "Project dir: $project_dir"
echo "Project: $project"
echo "Repo: $project_repo"
Project dir: /home/ava-dn/.vscode
Project: /home/ava-dn/.vscode/avas_2025
Repo: https://github.com/ava-dn/avas_2025.git
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Using conditional statement to create a project directory and project"

cd ~    # start in home directory

# Conditional block to make a project directory
if [ ! -d $project_dir ]
then 
    echo "Directory $project_dir does not exist... making directory $project_dir"
    mkdir -p $project_dir
fi
echo "Directory $project_dir exists." 

# Conditional block to git clone a project from project_repo
if [ ! -d $project ]
then
    echo "Directory $project does not exist... cloning $project_repo"
    cd $project_dir
    git clone $project_repo
    cd ~
fi
echo "Directory $project exists."
Using conditional statement to create a project directory and project
Directory /home/ava-dn/.vscode exists.
Directory /home/ava-dn/.vscode/avas_2025 exists.
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Navigate to project, then navigate to area wwhere files were cloned"
cd $project
pwd

echo ""
echo "list top level or root of files with project pulled from github"
ls
Navigate to project, then navigate to area wwhere files were cloned
/home/ava-dn/.vscode/avas_2025

list top level or root of files with project pulled from github
404.html
Foundation
Gemfile
LICENSE
Makefile
README.md
README4YML.md
_config.yml
_includes
_layouts
_notebooks
_sass
assets
images
index.md
navigation
requirements.txt
scripts
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Navigate to project, then navigate to area wwhere files were cloned"
cd $project
pwd

echo ""
echo "list all files in long format"
ls -al   # all files -a (hidden) in -l long listing
Navigate to project, then navigate to area wwhere files were cloned
/home/ava-dn/.vscode/avas_2025

list all files in long format
total 116
drwxr-xr-x 14 ava-dn ava-dn  4096 Sep 17 14:06 .
drwxr-xr-x  3 ava-dn ava-dn  4096 Sep 17 14:06 ..
drwxr-xr-x  8 ava-dn ava-dn  4096 Sep 17 14:06 .git
drwxr-xr-x  3 ava-dn ava-dn  4096 Sep 17 14:06 .github
-rw-r--r--  1 ava-dn ava-dn   251 Sep 17 14:06 .gitignore
drwxr-xr-x  2 ava-dn ava-dn  4096 Sep 17 14:06 .vscode
-rw-r--r--  1 ava-dn ava-dn   436 Sep 17 14:06 404.html
drwxr-xr-x  4 ava-dn ava-dn  4096 Sep 17 14:06 Foundation
-rw-r--r--  1 ava-dn ava-dn   122 Sep 17 14:06 Gemfile
-rw-r--r--  1 ava-dn ava-dn 11357 Sep 17 14:06 LICENSE
-rw-r--r--  1 ava-dn ava-dn  3549 Sep 17 14:06 Makefile
-rw-r--r--  1 ava-dn ava-dn 14171 Sep 17 14:06 README.md
-rw-r--r--  1 ava-dn ava-dn    85 Sep 17 14:06 README4YML.md
-rw-r--r--  1 ava-dn ava-dn   851 Sep 17 14:06 _config.yml
drwxr-xr-x  4 ava-dn ava-dn  4096 Sep 17 14:06 _includes
drwxr-xr-x  2 ava-dn ava-dn  4096 Sep 17 14:06 _layouts
drwxr-xr-x  3 ava-dn ava-dn  4096 Sep 17 14:06 _notebooks
drwxr-xr-x  4 ava-dn ava-dn  4096 Sep 17 14:06 _sass
drwxr-xr-x  5 ava-dn ava-dn  4096 Sep 17 14:06 assets
drwxr-xr-x  3 ava-dn ava-dn  4096 Sep 17 14:06 images
-rw-r--r--  1 ava-dn ava-dn  1150 Sep 17 14:06 index.md
drwxr-xr-x  2 ava-dn ava-dn  4096 Sep 17 14:06 navigation
-rw-r--r--  1 ava-dn ava-dn    57 Sep 17 14:06 requirements.txt
drwxr-xr-x  2 ava-dn ava-dn  4096 Sep 17 14:06 scripts
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Look for posts"
export posts=$project/_posts  # _posts inside project
cd $posts  # this should exist per fastpages
pwd  # present working directory
ls -lR  # list posts recursively
Look for posts
/home/ava-dn/nighthawk/avas_2025/_notebooks/Foundation


bash: line 7: cd: /home/ava-dn/.vscode/avas_2025/_posts: No such file or directory


.:
total 56
-rw-r--r-- 1 ava-dn ava-dn  3514 Sep 17 14:05 2024-08-21-sprint1_plan.ipynb
-rw-r--r-- 1 ava-dn ava-dn     0 Sep 17 13:40 2024-09-05-Javascript_Snippet.md
-rw-r--r-- 1 ava-dn ava-dn 44817 Sep 17 14:08 2024-09-05-Verify.ipynb
drwxr-xr-x 2 ava-dn ava-dn  4096 Sep  4 13:53 A-pair_programming
drwxr-xr-x 2 ava-dn ava-dn  4096 Sep  4 13:53 B-tools_and_equipment

./A-pair_programming:
total 16
-rw-r--r-- 1 ava-dn ava-dn  3918 Sep  4 13:53 2023-08-16-pair_showcase.ipynb
-rw-r--r-- 1 ava-dn ava-dn 11624 Sep  4 13:53 2023-08-17-pair_habits.ipynb

./B-tools_and_equipment:
total 112
-rw-r--r-- 1 ava-dn ava-dn  9767 Sep  4 13:53 2023-08-19-devops_accounts.ipynb
-rw-r--r-- 1 ava-dn ava-dn  5931 Sep  4 13:53 2023-08-21-devops_tools-home.ipynb
-rw-r--r-- 1 ava-dn ava-dn 22859 Sep  4 13:53 2023-08-21-devops_tools-setup.ipynb
-rw-r--r-- 1 ava-dn ava-dn 23150 Sep  4 13:53 2023-08-22-devops_tools-verify.ipynb
-rw-r--r-- 1 ava-dn ava-dn 32309 Sep  4 13:53 2023-08-23-devops-githhub_pages-play.ipynb
-rw-r--r-- 1 ava-dn ava-dn  9478 Sep  4 13:53 2023-08-23-devops-hacks.ipynb
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Look for notebooks"
export notebooks=$project/_notebooks  # _notebooks is inside project
cd $notebooks   # this should exist per fastpages
pwd  # present working directory
ls -lR  # list notebooks recursively
Look for notebooks
/home/ava-dn/.vscode/avas_2025/_notebooks
.:
total 4
drwxr-xr-x 4 ava-dn ava-dn 4096 Sep 17 14:06 Foundation

./Foundation:
total 24
-rw-r--r-- 1 ava-dn ava-dn  3509 Sep 17 14:06 2024-08-21-sprint1_plan.ipynb
-rw-r--r-- 1 ava-dn ava-dn     0 Sep 17 14:06 2024-09-05-Javascript_Snippet.md
-rw-r--r-- 1 ava-dn ava-dn 10266 Sep 17 14:06 2024-09-05-Jupiter_Notebook.md
drwxr-xr-x 2 ava-dn ava-dn  4096 Sep 17 14:06 A-pair_programming
drwxr-xr-x 2 ava-dn ava-dn  4096 Sep 17 14:06 B-tools_and_equipment

./Foundation/A-pair_programming:
total 16
-rw-r--r-- 1 ava-dn ava-dn  3918 Sep 17 14:06 2023-08-16-pair_showcase.ipynb
-rw-r--r-- 1 ava-dn ava-dn 11624 Sep 17 14:06 2023-08-17-pair_habits.ipynb

./Foundation/B-tools_and_equipment:
total 112
-rw-r--r-- 1 ava-dn ava-dn  9767 Sep 17 14:06 2023-08-19-devops_accounts.ipynb
-rw-r--r-- 1 ava-dn ava-dn  5931 Sep 17 14:06 2023-08-21-devops_tools-home.ipynb
-rw-r--r-- 1 ava-dn ava-dn 22859 Sep 17 14:06 2023-08-21-devops_tools-setup.ipynb
-rw-r--r-- 1 ava-dn ava-dn 23150 Sep 17 14:06 2023-08-22-devops_tools-verify.ipynb
-rw-r--r-- 1 ava-dn ava-dn 32309 Sep 17 14:06 2023-08-23-devops-githhub_pages-play.ipynb
-rw-r--r-- 1 ava-dn ava-dn  9478 Sep 17 14:06 2023-08-23-devops-hacks.ipynb
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Look for images, print working directory, list files"
cd $project/images  # this should exist per fastpages
pwd
ls -lR
Look for images, print working directory, list files
/home/ava-dn/.vscode/avas_2025/images
.:
total 2236
-rw-r--r-- 1 ava-dn ava-dn 2229569 Sep 17 14:06 coco.jpg
-rw-r--r-- 1 ava-dn ava-dn   15406 Sep 17 14:06 favicon.ico
-rw-r--r-- 1 ava-dn ava-dn   34239 Sep 17 14:06 logo.png
drwxr-xr-x 3 ava-dn ava-dn    4096 Sep 17 14:06 notebooks

./notebooks:
total 4
drwxr-xr-x 2 ava-dn ava-dn 4096 Sep 17 14:06 foundation

./notebooks/foundation:
total 364
-rw-r--r-- 1 ava-dn ava-dn 310743 Sep 17 14:06 create_repo.png
-rw-r--r-- 1 ava-dn ava-dn  29416 Sep 17 14:06 push.jpg
-rw-r--r-- 1 ava-dn ava-dn  17105 Sep 17 14:06 stage.jpg
-rw-r--r-- 1 ava-dn ava-dn   6659 Sep 17 14:06 wsl.jpg
%%script bash

# Extract saved variables
source /tmp/variables.sh

echo "Navigate to project, then navigate to area wwhere files were cloned"

cd $project
echo "show the contents of README.md"
echo ""

cat README.md  # show contents of file, in this case markdown
echo ""
echo "end of README.md"

Navigate to project, then navigate to area wwhere files were cloned
show the contents of README.md

# Introduction

Nighthawk Pages is a project designed to support students in their Computer Science and Software Engineering education. It offers a wide range of resources including tech talks, code examples, and educational blogs.

GitHub Pages can be customized by the blogger to support computer science learnings as the student works through the pathway of using Javascript, Python/Flask, Java/Spring.  

## Student Requirements

Del Norte HS students will be required to review their personal GitHub Pages at each midterm and final.  This review will contain a compilation of personal work performed within each significant grading period.

In general, Students and Teachers are expected to use GitHub pages to build lessons, complete classroom hacks, perform work on JavaScript games, and serve as a frontend to full-stack applications.

Exchange of information could be:

1. sharing a file:  `wget "raw-link.ipynb"
2. creating a template from this repository
3. sharing a fork among team members
4. etc.

---

## History

This project is in its 3rd revision (aka 3.0).

The project was initially based on Fastpages. But this project has diverged from those roots into an independent entity.  The decision to separate from Fastpages was influenced by the deprecation of Fastpages by authors.  It is believed by our community that the authors of fastpages turned toward Quatro.  After that change of direction fastpages did not align with the Teacher's goals and student needs. The Nighthawk Pages project has more of a raw development blogging need.

### License

The Apache license has its roots in Fastpages.  Thus, it carries its license forward.  However, most of the code is likely unrecognizable from those roots.

### Key Features

- **Code Examples**: Provides practical coding examples in JavaScript, including a platformer game, and frontend code for user databases using Python and Java backends.
- **Educational Blogs**: Offers instructional content on various topics such as developer tools setup, deployment on AWS, SQL databases, machine learning, and data structures. It utilizes Jupyter Notebooks for interactive lessons and coding challenges.
- **Tools and Integrations**: Features GitHub actions for blog publishing, Utterances for blog commenting, local development support via Makefile and scripts, and styling with the Minima Theme and SASS. It also includes a new integration with GitHub Projects and Issues.

### Contributions

- **Notable Contributions**: Highlights significant contributions to the project, including theme development, search and tagging functionality, GitHub API integration, and the incorporation of GitHub Projects into GitHub pages. Contributors such as Tirth Thakker, Mirza Beg, and Toby Ledder have played crucial roles in these developments.

- **Blog Contributions**:  Often students contribute articles and blogs to this project.  Their names are typically listed in the front matter of their contributing post.

---

## GitHub Pages setup

The absolutes in setup up...

**Activate GitHub Pages Actions**: This step involves enabling GitHub Pages Actions for your project. By doing so, your project will be automatically deployed using GitHub Pages Actions, ensuring that your project is always up to date with the latest changes you push to your repository.

- On the GitHub website for the repository go to the menu: Settings -> Pages ->Build
- Under the Deployment location on the page, select "GitHub Actions".

**Update `_config.yml`**: You need to modify the `_config.yml` file to reflect your repository's name. This configuration is crucial because it ensures that your project's styling is correctly applied, making your deployed site look as intended rather than unstyled or broken.

```text
github_repo: "student_2025" 
baseurl: "/student_2025"
```

**Set Repository Name in Makefile**: Adjust the `REPO_NAME` variable in your Makefile to match your GitHub repository's name. This action facilitates the automatic updating of posts and notebooks on your local development server, improving the development process.

```make
# Configuration, override port with usage: make PORT=4200
PORT ?= 4100
REPO_NAME ?= student_2025
LOG_FILE = /tmp/jekyll$(PORT).log
```

### Tool requirements

All `GitHub Pages` websites are managed on GitHub infrastructure and use GitHub version control.  Each time we change files in GitHub it initiates a GitHub Action, a continuous integration and development toolset, that rebuilds and publishes the site with Jekyll.  

- GitHub uses `Jekyll` to transform your markdown and HTML content into static websites and blogs. [Jekyll](https://jekyllrb.com/).
- A Linux shell is required to work with this project integration with GitHub Pages, GitHub and VSCode.  Ubuntu is the preferred shell, though MacOS shell is supported as well.  There will be some key setup scripts that follow in the README.
- Visual Studio Code is the Nighthawk Pages author's preferred code editor and extensible development environment.  VSCode has a rich ecosystem of developer extensions that ease working with GitHub Pages, GitHub, and many programming languages.  Setting up VSCode and extensions will be elaborated upon in this document.
- An anatomy section in this README will describe GitHub Pages and conventions that are used to organize content and files.  This includes file names, key coding files, metadata tagging of blogs, styling tooling for blogs, etc.

### Development Environment Setup

Comprehensive start. A topic-by-topic guide to getting this project running is published [here](https://nighthawkcoders.github.io/portfolio_2025/devops/tools/home).

Quick start.  A quick start below is a reminder, but is dependent on your knowledge.  Only follow this instruction if you need a refresher.  Always default to the comprehensive start if any problem occurs.

#### Clone Repo

Run these commands to obtain the project, then locate into the project directory with the terminal, install an extensive set of tools, and make.

```bash
git clone <this-repo> # git clone https://github.com/nighthawkcoders/student_2025.git 
cd <repo-dir>/scripts # cd student_2025
```

#### Windows WSL and/or Ubuntu Users

- Execute the script: `./activate_ubuntu.sh`

#### macOS Users

- Execute the script: `./activate_macos.sh`

#### Kasm Cloud Desktop Users

- Execute the script: `./activate.sh`

## Run Server on localhost

To preview the project you will need to "make" the project.

### Bundle install

The very first time you clone run project you will need to run this Ruby command as the final part of your setup.

```bash
bundle install
```

### Start the Server  

This requires running terminal commands `make`, `make stop`, `make clean`, or `make convert` to manage the running server.  Logging of details will appear in the terminal.   A `Makefile` has been created in the project to support commands and start processes.

Start the server, this is the best choice for initial and iterative development.  Note. after the initial `make`, you should see files automatically refresh in the terminal on VSCode save.

  ```bash
  make
  ```

### Load web application into the Browser

Start the preview server in the terminal,
The terminal output from `make` shows the server address. "Cmd" or "Ctl" click the http location to open the preview server in a browser. Here is an example Server address message, click on the Server address to load:...

  ```text
  http://0.0.0.0:4100/student_2025/
  ```

### Regeneration of web application

Save on ".ipynb" or ".md" file activiates "regeneration". An example terminal message is below.  Refresh the browser to see updates after the message displays.

  ```text
  Regenerating: 1 file(s) changed at 2023-07-31 06:54:32
      _notebooks/2024-01-04-cockpit-setup.ipynb
  ```

### Other "make" commands

Terminal messages are generated from background processes.  At any time, click return or enter in a terminal window to obtain a prompt.  Once you have the prompt you can use the terminal as needed for other tasks.  Always return to the root of project `cd ~/vscode/student_2025` for all "make" actions.

#### Stop the preview server

Stopping the server ends the web server applications running process.  However, it leaves constructed files in the project in a ready state for the next time you run `make`.

  ```bash
  make stop
  ```

### Clean the local web application environment

This command will top the server and "clean" all previously constructed files (ie .ipynb -> .md). This is the best choice when renaming files has created duplicates that are visible when previewing work.

  ```bash
  make clean
  ```

### Observe build errors

Test Jupyter Notebook conversions (ie .ipynb -> .md), this is the best choice to see if an IPYNB conversion error is occurring.

  ```bash
  make convert
  ```

---

## Development Support

### File Names in "_posts", "_notebooks"

There are two primary directories for creating blogs.  The "_posts" directory is for authoring in markdown only.  The "_notebooks" allows for markdown, pythons, javascript and more.

To name a file, use the following structure (If dates are in the future, review your config.yml setting if you want them to be viewed).  Review these naming conventions.

- For markdown files in _posts:
  - year-month-day-fileName.md
    - GOOD EXAMPLE: 2021-08-02-First-Day.md
    - BAD EXAMPLE: 2021-8-2-first-day.md
    - BAD EXAMPLE: first-day.md
    - BAD EXAMPLE: 2069-12-31-First-Day.md

- For Jupyter notebooks in _notebooks:
  - year-month-day-fileName.ipynb
    - GOOD EXAMPLE: 2021-08-02-First-Day.ipynb
    - BAD EXAMPLE: 2021-8-2-first-day.ipynb
    - BAD EXAMPLE: first-day.ipynb
    - BAD EXAMPLE: 2069-12-31-First-Day.ipynb

### Tags

Tags are used to organize pages by their tag the way to add tags is to add the following to your front matter such as the example seen here `categories: [Tools]` Each item in the same category will be lumped together to be seen easily on the search page.

### Search

All pages can be searched for using the built-in search bar. This search bar will search for any word in the title of a page or in the page itself. This allows for easily finding pages and information that you are looking for. However, sometimes this may not be desirable so to hide a page from the search you need to add `search_exclude: true` to the front matter of the page. This will hide the page from appearing when the viewer uses search.

### Navigation Bar

To add pages to the top navigation bar use _config.yml to order and determine which menus you want and how to order them.  Review the_config.yml in this project for an example.

### Blog Page

There is a blog page that has options for images and a description of the page. This page can help the viewer understand what the page is about and what they can expect to find on the page. The way to add images to a page is to have the following front matter `image: /images/file.jpg` and then the name of the image that you want to use. The image must be in the `images` folder. Furthermore, if you would like the file to not show up on the blog page `hide: true` can be added to the front matter.

### SASS support

NIGHTHAWK Pages support a variety of different themes that are each overlaid on top of minima. To use each theme, go to the "_sass/minima/custom-styles.scss" file and simply comment or uncomment the theme you want to use.

To learn about the minima themes search for "GitHub Pages minima" and review the README.

To find a new theme search for "Github Pages Themes".

### Includes

- Nighthawk Pages uses liquid syntax to import many common page elements that are present throughout the repository. These common elements are imported from the _includes directory. If you want to add one of these common elements, use liquid syntax to import the desired element to your file. Here’s an example of the liquid syntax used to import: `<h3>
<a class="post-link" href="">

</a>

</h3><p class="post-meta"></p> ` Note that the liquid syntax is surrounded by curly braces and percent signs. This can be used anywhere in the repository.

### Layouts

- To use or create a custom page layout, make an HTML page inside the _layouts directory, and when you want to use that layout in a file, use the following front matter `layout: [your layout here]`.  All layouts will be written in liquid to define the structure of the page.

### Metadata

Metadata, also known as "front matter", is a set of key-value pairs that can provide additional information to GitHub Pages about .md and .ipynb files. This can and probably will be used in other file types (ie doc, pdf) if we add them to the system.

In the front matter, you can also define things like a title and description for the page.  Additional front matter is defined to place content on the "Computer Science Lab Notebook" page.  The `courses:` key will place data on a specific page with the nested `week:` placing data on a specific row on the page.  The `type:` key in "front matter" will place the blog under the plans, hacks(ToDo), and tangibles columns.

- In our files, the front matter is defined at the top of the page or the first markdown cell.

  - First, open one of the .md or .ipynb files already included in either your _posts|_notebooks folder.

  - In the .md file, you should notice something similar to this at the top of the page. To see this in your .ipynb files you will need to double-click the markdown cell at the top of the file.

  ```yaml
  ---
  toc: true
  comments: true
  layout: post
  title: Jupyter Python Sample
  description: Example Blog!!!  This shows code and notes from hacks.
  type: ccc
  courses: { csa: {week: 5} }
  ---
  ```

- The front matter will always have '---' at the top and bottom to distinguish it and each key-value pair will be separated by a ':'.

- Here we can modify things like the title and description.

- The type value will tell us which column this is going to appear under the time box supported pages.  The "ccc" stands for Code, Code, Code.

- The courses will tell us which menu item it will be under, in this case, the `csa` menu, and the `week` tells it what row (week) it will appear under that menu.

end of README.md
%%script bash

# This command has no dependencies

echo "Show the shell environment variables, key on left of equal value on right"
echo ""

env
Show the shell environment variables, key on left of equal value on right

SHELL=/bin/bash
PYTHONUNBUFFERED=1
WSL2_GUI_APPS_ENABLED=1
WSL_DISTRO_NAME=Ubuntu-24.04
PYTHON_FROZEN_MODULES=on
ELECTRON_RUN_AS_NODE=1
VSCODE_AMD_ENTRYPOINT=vs/workbench/api/node/extensionHostProcess
NAME=LAPTOP-ARHAPHAQ
PWD=/home/ava-dn/nighthawk/avas_2025/_notebooks/Foundation
LOGNAME=ava-dn
PYDEVD_IPYTHON_COMPATIBLE_DEBUGGING=1
HOME=/home/ava-dn
LANG=C.UTF-8
WSL_INTEROP=/run/WSL/115446_interop
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=00:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.avif=01;35:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:*~=00;90:*#=00;90:*.bak=00;90:*.crdownload=00;90:*.dpkg-dist=00;90:*.dpkg-new=00;90:*.dpkg-old=00;90:*.dpkg-tmp=00;90:*.old=00;90:*.orig=00;90:*.part=00;90:*.rej=00;90:*.rpmnew=00;90:*.rpmorig=00;90:*.rpmsave=00;90:*.swp=00;90:*.tmp=00;90:*.ucf-dist=00;90:*.ucf-new=00;90:*.ucf-old=00;90:
VIRTUAL_ENV=/home/ava-dn/nighthawk/avas_2025/venv
WAYLAND_DISPLAY=wayland-0
FORCE_COLOR=1
PYDEVD_USE_FRAME_EVAL=NO
CLICOLOR=1
VSCODE_L10N_BUNDLE_LOCATION=
CLICOLOR_FORCE=1
GEM_HOME=/home/ava-dn/gems
LESSCLOSE=/usr/bin/lesspipe %s %s
VSCODE_HANDLES_SIGPIPE=true
TERM=xterm-color
LESSOPEN=| /usr/bin/lesspipe %s
USER=ava-dn
GIT_PAGER=cat
PYTHONIOENCODING=utf-8
DISPLAY=:0
SHLVL=1
PAGER=cat
VSCODE_CWD=/mnt/c/Users/avaro/AppData/Local/Programs/Microsoft VS Code
VIRTUAL_ENV_PROMPT=(venv) 
MPLBACKEND=module://matplotlib_inline.backend_inline
XDG_RUNTIME_DIR=/run/user/1002/
DEBUGINFOD_URLS=https://debuginfod.ubuntu.com 
WSLENV=VSCODE_WSL_EXT_LOCATION/up
VSCODE_WSL_EXT_LOCATION=/mnt/c/Users/avaro/.vscode/extensions/ms-vscode-remote.remote-wsl-0.88.3
XDG_DATA_DIRS=/usr/local/share:/usr/share:/var/lib/snapd/desktop
PATH=/home/ava-dn/nighthawk/avas_2025/venv/bin:/home/ava-dn/.vscode-server/bin/4849ca9bdf9666755eb463db297b69e5385090e3/bin/remote-cli:/home/ava-dn/gems/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/wsl/lib:/mnt/c/Windows/system32:/mnt/c/Windows:/mnt/c/Windows/System32/Wbem:/mnt/c/Windows/System32/WindowsPowerShell/v1.0/:/mnt/c/Windows/System32/OpenSSH/:/mnt/c/Users/avaro/AppData/Local/Microsoft/WindowsApps:/mnt/c/Users/avaro/AppData/Local/Programs/Microsoft VS Code/bin:/snap/bin
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1002/bus
VSCODE_NLS_CONFIG={"userLocale":"en","osLocale":"en","resolvedLanguage":"en","defaultMessagesFile":"/home/ava-dn/.vscode-server/bin/4849ca9bdf9666755eb463db297b69e5385090e3/out/nls.messages.json","locale":"en","availableLanguages":{}}
HOSTTYPE=x86_64
PULSE_SERVER=unix:/mnt/wslg/PulseServer
VSCODE_HANDLES_UNCAUGHT_ERRORS=true
VSCODE_IPC_HOOK_CLI=/run/user/1002/vscode-ipc-120fb28a-f986-423a-b284-41dfb6002b35.sock
_=/usr/bin/env
%%script bash

# Extract saved variables
source /tmp/variables.sh

cd $project

echo ""
echo "show the secrets of .git config file"
cd .git
ls -l config

echo ""
echo "look at config file"
cat config
show the secrets of .git config file
-rw-r--r-- 1 ava-dn ava-dn 260 Sep 17 14:06 config

look at config file
[core]
	repositoryformatversion = 0
	filemode = true
	bare = false
	logallrefupdates = true
[remote "origin"]
	url = https://github.com/ava-dn/avas_2025.git
	fetch = +refs/heads/*:refs/remotes/origin/*
[branch "main"]
	remote = origin
	merge = refs/heads/main
%%script bash

# This example has an error in VSCode; it runs best on Jupyter
cd /tmp

file="sample.md"
if [ -f "$file" ]; then
    rm $file
fi

# Create a markdown file using tee and here document (<<EOF)
tee -a $file >/dev/null <<EOF
# Show Generated Markdown
This introductory paragraph and this line and the title above are generated using tee with the standard input (<<) redirection operator.
- This bulleted element is still part of the tee body.
EOF

# Append additional lines to the markdown file using echo and redirection (>>)
echo "- This bulleted element and lines below are generated using echo with standard output (>>) redirection operator." >> $file
echo "- The list definition, as is, is using space to separate lines. Thus the use of commas and hyphens in output." >> $file

# Define an array of actions and their descriptions
actions=("ls,list-directory" "cd,change-directory" "pwd,present-working-directory" "if-then-fi,test-condition" "env,bash-environment-variables" "cat,view-file-contents" "tee,write-to-output" "echo,display-content-of-string" "echo_text_>\$file,write-content-to-file" "echo_text_>>\$file,append-content-to-file")

# Loop through the actions array and append each action to the markdown file
for action in ${actions[@]}; do
  action=${action//-/ }  # Convert dash to space
  action=${action//,/: } # Convert comma to colon
  action=${action//_text_/ \"sample text\" } # Convert _text_ to "sample text", note escape character \ to avoid "" having meaning
  echo "    - ${action//-/ }" >> $file  # Append action to file
done

echo ""
echo "File listing and status"
ls -l $file # List file details
wc $file   # Show word count
mdless $file  # Render markdown from terminal (requires mdless installation)

rm $file  # Clean up temporary file
File listing and status
-rw-r--r-- 1 ava-dn ava-dn 808 Sep 17 14:08 sample.md


 15 132 808 sample.md


bash: line 36: mdless: command not found
%%script bash

# This example has an error in VSCode; it runs best on Jupyter
cd /tmp

file="sample.md"
if [ -f "$file" ]; then
    rm $file
fi

# Set locale to C to avoid locale-related errors
export LC_ALL=C

# Create a markdown file using tee and here document (<<EOF)
tee -a $file >/dev/null <<EOF
# Show Generated Markdown
This introductory paragraph and this line and the title above are generated using tee with the standard input (<<) redirection operator.
- This bulleted element is still part of the tee body.
EOF

# Append additional lines to the markdown file using echo and redirection (>>)
echo "- This bulleted element and lines below are generated using echo with standard output (>>) redirection operator." >> $file
echo "- The list definition, as is, is using space to separate lines. Thus the use of commas and hyphens in output." >> $file

# Define an array of commands
commands=("ls" "cat" "tail" "pwd" "env" "grep" "awk" "sed" "curl" "wget")

# Loop through the commands array and append each command description to the markdown file
for cmd in ${commands[@]}; do
  description=$(man $cmd | col -b | awk '/^NAME/{getline; print}')
  echo "    - $description" >> $file
done

echo ""
echo "File listing and status"
ls -l $file # List file details
wc $file   # Show word count
mdless $file  # Render markdown from terminal (requires mdless installation)

rm $file  # Clean up temporary file
troff:<standard input>:1039: warning [p 9, 0.2i]: cannot adjust line
troff:<standard input>:1296: warning [p 11, 5.2i]: cannot adjust line
troff:<standard input>:254: warning [p 3, 3.7i]: cannot adjust line
troff:<standard input>:583: warning [p 6, 0.2i]: cannot adjust line
troff:<standard input>:645: warning [p 6, 6.5i]: cannot adjust line
troff:<standard input>:664: warning [p 6, 8.7i]: cannot adjust line
troff:<standard input>:728: warning [p 7, 4.5i]: cannot adjust line
troff:<standard input>:746: warning [p 7, 6.3i]: cannot adjust line
troff:<standard input>:784: warning [p 8, 0.0i]: cannot adjust line
troff:<standard input>:1138: warning [p 11, 3.5i]: cannot adjust line
troff:<standard input>:1414: warning [p 13, 6.2i]: cannot adjust line
troff:<standard input>:1415: warning [p 13, 6.5i]: cannot adjust line
troff:<standard input>:1471: warning [p 13, 12.3i]: cannot adjust line
troff:<standard input>:1652: warning [p 15, 0.0i]: cannot adjust line
troff:<standard input>:1652: warning [p 15, 0.2i]: cannot adjust line
troff:<standard input>:1652: warning [p 15, 0.3i]: cannot adjust line
troff:<standard input>:1746: warning [p 15, 10.3i]: cannot adjust line
troff:<standard input>:1794: warning [p 16, 0.7i]: cannot adjust line
troff:<standard input>:1794: warning [p 16, 0.8i]: cannot adjust line
troff:<standard input>:1794: warning [p 16, 1.0i]: cannot adjust line
troff:<standard input>:1936: warning [p 16, 13.5i]: cannot adjust line
troff:<standard input>:1956: warning [p 17, 1.7i]: cannot adjust line
troff:<standard input>:1956: warning [p 17, 1.8i]: cannot adjust line
troff:<standard input>:2409: warning [p 20, 7.5i]: cannot adjust line
troff:<standard input>:526: warning [p 9, 5.2i]: cannot break line
troff:<standard input>:2226: warning [p 36, 9.0i]: cannot adjust line
troff:<standard input>:2261: warning [p 37, 3.2i]: cannot adjust line
troff:<standard input>:2559: warning [p 42, 0.3i]: cannot break line



File listing and status
-rw-r--r-- 1 ava-dn ava-dn 1016 Sep 17 14:08 sample.md
  15  159 1016 sample.md


bash: line 37: mdless: command not found