text:
# Using Git

> This cheat-sheet is also available on [my website](https://hnqiu.github.io/cheatsheets/2019/05/19/using-git.html).

Git is a distributed version control system for tracking code histories. If you are using MacOS or Ubuntu, Git should have been installed by default, otherwise follow the instructions on [git-scm](https://git-scm.com/downloads) to install it.

For complete beginners I would recommend [a Git tutorial on Corey Schafer's Youtube channel](https://www.youtube.com/watch?v=HVsySz-h9r4). That's how I first learnt Git.

## Common Git Commands

### First-Time Setup
Once git is installed, we need to set up the user name and email address because these user identity variables are required for every git commit.
We can use
```sh
git config --[option] <variable> "value"
```
to configure these variables, with `[option]` indicating the level of the git config file.

Usually we specify the `--global` option to set up the configuration to be used across all repositories we are working with, in which case the configuration will be stored in the `~/.gitconfig` file (this configuration only needs to be done once). We can also specify the `--local` option so that it can only affect the single current repository. In this case it will be stored in the `${git-repo-dir}/.git/config`.

Command | Description
------- | :-----------
`git config --global user.name "<name>"`    | set up user name to be used across all repos
`git config --global user.email "<email>"`  | set up email address to be used across all repos
`git config --list`     | list git configuration
`git config --global -e`| open config file
`git config --global core.editor "vim"`     | set git editor to vim
`git config --global push.default simple`   | set push default behaviour

`push.default` can be set as `matching` or `simple`. `matching` means git will push all local branches to the remote with the matching name. `simple` means only the current branch -- this is the default setting from Git 2.0.

### Initialization
When initializing a git repository, we either create a new one or clone one from remote.

Command             | Description
-------             | :-----------
`git init`          | initialize an existing dir as a git repo
`git clone <url>`   | clone a repo
`git help [command]` or
 `git [command] --help`    | get help info

### Adding & Modifying Files
Command         | Description
-------         | :-----------
`git status`    | check status
`git add [file]`| add a file to the staging area
`git add -A`    | add all files in the directory to the staging area
`git reset [file]`  | remove a file from the staging area
`git reset`         | remove all from the staging area
`git commit -m "[message]"` | commit staged contents
`git commit -am "[message]"`| stage all files that have been modified or added and commit
`git add --patch [file]` or
 `git add -p [file]`    | stage parts/hunks of a file, prompted with options, e.g.,
 `y`: stage this hunk
 `n`: do not stage this hunk
 `s`: split the current hunk into smaller hunks
 `q`: quit
 `?` help

### Pull Push
To avoid consistently entering username and password when pushing repositories to GitHub, it is better to establish a secure connection by setting up an SSH key in our GitHub account.
First generate a pair of SSH keys following [my SSH tutorial](https://hnqiu.github.io/2019/04/30/using-ssh.html#more-secure-authentication) and add the public key to the account following [this help document](https://help.github.com/articles/adding-a-new-ssh-key-to-your-github-account/), beginning from **step 2**.
Finally, use `set-url` to change the remote url to SSH.
:exclamation: Do **NOT** share the private key `id_rsa` with anyone.

Command | Description
------- | :-----------
`git push` or
 `git push origin [branchname]` | push changes to the remote repo
 `origin` is an alias on the local system for the remote repo
`git push -u origin [branchname]`                 | push changes to the remote repo and associate local branch with the remote repo
`git push origin --delete [branch]` or
 `git push origin :[branch]` | delete a remote branch
`git fetch`                     | fetch updates from remote branches but do not change the local copy
`git fetch --prune`             | clean outdated branches that do not exist on the remote
`git pull origin [branchname]`  | pull changes from the remote branch: `fetch` and `merge`
`git reset origin/master`       | set local repo to match the remote branch (after `git fetch`)
`git remote -v`                 | list remote repos
`git remote add origin https://github.com/<user>/[reponame].git`    | connect remote server to local
`git remote add origin git@github.com:<user>/[reponame].git`        | or use SSH if it is set
`git remote get-url --all origin`                                   | get remote's url
`git remote set-url origin git@github.com:<user>/[reponame].git`    | set remote's url with ssh
`git remote rm origin`          | remove the remote repo `origin`
`git stash`                     | save the current changes on a stack
`git stash push -m <stash_name>`| stash changes with given name
`git stash list`                | list stored stashes
`git stash apply <stash@>`      | reapply the stashed changes

### Branch & Merge
Command | Description
------- | :-----------
`git checkout [branchname]` | switch to branch
`git checkout -b [branch]`  | create a branch and switch to it
`git branch`                | list local branches (the asterisk mark `*` denotes the current branch)
`git branch -a`             | list all branches
`git branch [branchname]`   | create a branch
`git branch -d [branch]`    | delete a local branch
`git branch -D [branch]`    | force delete a branch even it is not fully merged
`git merge [branchname]`    | merge the branch into the current working branch
`git merge <commitID>`      | merge the change history prior to (including) the specified commit into the current working branch
`git branch --merged`       | show branches that have been merged into the current branch

## Use `hub` from Command-Line

### Installation
`hub` is a [GitHub extension](https://hub.github.com/) to make GitHub tasks easier. Download [`hub` release](https://github.com/github/hub/releases), extract and install it. For instance,

- Ubuntu
  Extract the release to `./hub/` and
  ```
  cd hub
  sudo ./install
  ```

- Windows
  Extract the release and run the `install.bat` file. Use `hub` in `git-bash.exe` instead of in `cmd.exe`, otherwise you would need to add `C:\Program Files\Git\bin` to **System Path**.

### Commands
Command | Description
------- | :-----------
`hub create`            | create a repo with default settings
`hub create -p`         | create a private repo
`hub create -d [desc]`  | create a repo with description

For full documentation visit the [`hub` manual](https://hub.github.com/hub.1.html).

## A Simple Workflow
In this example, we are going to create a repository and connect it to GitHub. We are going to create a local `master` branch first and connect it remotely. Then we will also create a daily working branch, and push it to GitHub for our everyday work. Once we have completed a major section, we merge it into the `master` and push the `master` to remote.
- For first-time users, set up git configuration and SSH keys
  ```sh
  # git config
  git config --global user.name "<name>"
  git config --global user.email "<email addr>"

  # generate ssh keys
  # and add the public key on github
  ```
  :exclamation: `id_rsa.pub` is the public key. Do **NOT** paste the `id_rsa`.

- Either clone a repository from remote or create a local repository and push it to github:
  ```sh
  # clone a remote repo
  cd [workspace]
  git clone <url>
  git branch -a # to list local and remote branches
  ```

  ```sh
  # create a local git repo and push to remote
  # in this case, we also need to create a repo on github
  # the simple way is to create one on the website
  # or you can use `hub` command
  cd [repodir]
  git init
  touch [newfile] # and add some contents
  git add [file] # use `git status` to see if it's staged
  git commit -m "msg" # or use `git commit -am "msg"` to replace the last two commands

  # create a repo on github then use the following `git remote` to connect them
  git remote add origin git@github.com:<user>/[reponame].git
  # or use `hub` command
  hub create

  # then
  git push origin master
  git branch -a # will list a local and remote `master` branch
  ```

- Edit files and update the repository in a local working branch
  ```sh
  # create a working branch and do everyday tasks in it
  git checkout -b [branch]
  touch [file] # and modify
  git add [file]
  git commit -m "msg"
  # then push to remote
  git push -u origin [branch]
  ```

- Merge the working branch into master
  ```sh
  # merge into master
  git checkout master
  git pull origin master
  git merge [branch] # use `git branch --merged` to show merged branches
  git push origin master
  ```

## More Advanced Commands

### Version Control
Syntax | Description
------- | :-----------
`<rev>^1` or `<rev>^`                   | the first parent of the specified commit object
`<rev>^n`                               | the `<n>`th parent of that commit
`<rev>^^` or `<rev>~2`                  | the first grand-parent of the specified commit object following the first parent

Command | Description
------- | :-----------
`git log`                               | show git log
`git log --oneline`                     | show abbreviated git log in one-line format
`git log --abbrev-commit`               | show git log with abbreviated commit IDs
`git log --stat`                        | show git log with change stat
`git log --author=<name>`               | show git log messages made by specified author
`git log --grep=<pattern>`              | show git log messages with the specified pattern
`git log --graph --oneline --all`       | show git log tree in all branches
`git show <commitID>`                   | show changes in that commit
`git diff`                              | show unstaged changes
`git diff --staged`                     | show changes between the staging area and last commit
`git diff <commitID>`                   | compare with the specified commit
`git diff <oldCommit>..<newCommit>`     | compare between two commits
`git diff --stat <oldCommit>..<newCommit>`  | show change stat (additions & deletions) between the two
`git commit --amend`                    | combine staged changes with the previous commit (commit message will be opened)
 `amend` will create an entirely new commit, instead of modifying the old commit
`git commit --amend -m "new msg"`       | change the most recent commit message to "new msg"
`git commit --amend --no-edit`          | commit staged changes to the previous commit without message editing
`git reset HEAD~`                       | undo the last commit and leave changes unstaged (`HEAD` will be copied to `.git/ORIG_HEAD`)
`git reset --soft HEAD~`                | undo the last commit and leave changes staged
`git reset --hard <commitID>`           | roll back local repo to the specified version and remove previous commits
`git reset --hard origin/[branch]`      | reset local branch to match the remote branch
`git push origin [branchname] --force`  | force push local repo to remote
`git revert <commitID>`                 | roll back files and create commit to record rollback history
`git cherry-pick <commitID>`            | merge changes from a commit
`git rebase [branchname]`               | rewrite the current branch history to follow the commits in the specified branch
`git rebase -i HEAD~2`                  | rebase specified last commits in interactive mode
`git rebase --continue`                 | continue with history rebasing in interactive mode
`git checkout <commitID> [file]`        | revert a specified file to the committed reversion and stage changes (not committed)
`git checkout <commitID>~1 [file]`      | revert a file to the first parent of the specified commit and stage changes

### Submodule
Command | Description
------- | :-----------
`git clone --recursive <url>`   | clone a repository including its submodules
`git pull --recurse-submodules` | pull changes in the repository including submodules
`git submodule add <url>`       | add an existing repository as a submodule under current directory
`git submodule init`            | initialize submodule configuration
`git submodule update --remote` | fetch and update all submodules

### Others
Command | Description
------- | :-----------
`git ls-files`  | list files under the current path that are being tracked

## Examples
- [Amending the most recent commit message](https://stackoverflow.com/questions/179123/how-to-modify-existing-unpushed-commits)
  ```sh
  git reset # unstaged changes since last commit
  git commit --amend -m "new msg" # or git commit --amend
  git push origin [branch] -f # force push commit if that commit was pushed before
  ```
- Change the last commit
  ```sh
  git commit -m "msg" # commit that needs to be changed
  # modify files and
  git add [files] # stage
  git commit --amend
  ```
- [Undo the most recent commit](https://stackoverflow.com/questions/927358/how-do-i-undo-the-most-recent-local-commits-in-git)
  ```sh
  git reset HEAD~ # undo commit and leave changes unstaged
  # or `git reset --soft HEAD~` to leave changes staged
  # edit files and
  git add [file]
  git commit -c ORIG_HEAD # open editor with previous change commit message
  git push origin [branch] -f # force push commit if that commit was pushed before
  ```
- Add an existing repository as a submodule
  ```sh
  # cd to the directory that keeps the submodule and
  git submodule add <url>
  git status # will show that the submodule folder is tracked as "new file"
  git submodule init
  # fetch and update the submodule
  git submodule update --remote [sub-repo]

  cd <sub-repo>
  git branch -a # should show it's in “detached HEAD” state
  git checkout master # [or] -b [newbranch]
  # make changes and commit, and
  git push origin [branch]

  cd <main-repo>
  git status # will show the submodule has "new commits"
  git add -A
  git commit -m "msg"
  git push # push main-repo to remote
  ```

## `.gitignore` Template
There is a [`.gitignore` template repository](https://github.com/github/gitignore) available. For `.gitignore` syntax please visit the [git document](https://git-scm.com/docs/gitignore).

repository: hnqiu/git-cheat-sheet

repo_name: hnqiu/git-cheat-sheet


text:
# note-taker2

## Overview

This is a note takiing app.

User is presented with home page with a button that leads to note taking page.

On the note taking page, user can put a title and note that will be saved to the left.

Saved notes can be deleted.

## Deployed Website
https://nameless-brook-20588.herokuapp.com/

## Licensed under
[MIT License](LICENSE)

license: MIT

branch_name: refs/heads/main

extension: md

license_type: permissive


text:
# Change Log

### Unreleased

* Update the `org.realityforge.guiceyloops` artifact to version `0.113`.
* Upgrade the `au.com.stocksoftware.idea.codestyle` artifact to version `1.17`.
* Upgrade the `javax` artifact to version `8.0`.
* Use a baseline Java version `17`.

### [v0.2](https://github.com/realityforge/simple-keycloak-service/tree/v0.2) (2020-08-21) · [Full Changelog](https://github.com/realityforge/simple-keycloak-service/compare/v0.1...v0.2)

* Remove `{@inheritDoc}` as it only explicitly indicates that the default behaviour at the expense of significant visual clutter.
* Update keycloak to version `11.0.0`
* Automate release process.

### [v0.1](https://github.com/realityforge/simple-keycloak-service/tree/v0.1) (2017-04-19) · [Full Changelog](https://github.com/realityforge/simple-keycloak-service/compare/1fd1321c91423263a05354538dd04f130a7ba0fd...v0.1)

* Initial release

repository: realityforge/simple-keycloak-service

branch_name: refs/heads/master

repo_name: realityforge/simple-keycloak-service


text:
# enron-bigdata

[![Build Status](https://travis-ci.org/seborama/enron-bigdata.svg?branch=master)](https://travis-ci.org/seborama/enron-bigdata)

Sainsbury's BigData test.

## Requirements

This project requires to download the Enron email dataset. A starting point may be:

https://www.cs.cmu.edu/~enron/

Extract the dataset and supply the path when running the application (see below).

## Maven

### Running the tests

```bash
mvn test
```

### Create the application JAR file

```bash
mvn package
ls -la target/seborama.enron-bigdata-1.0-SNAPSHOT.jar
```

### Running the application

You need to create the jar file first (see `mvn package` above)

```bash
java -jar seborama.enron-bigdata-1.0-SNAPSHOT.jar path/to/enron/v2/zip/files
```

`path/to/enron/v2/zip/files` references the path to the Enron email dataset as explained in the `Requirements`

### Building the maven reporting site

```bash
mvn site
```

The output is available from:

```bash
open target/site/index.html
```

### Generate Javadoc

```bash
mvn javadoc:javadoc
```

The output is available from:

```bash
open target/site/apidocs/index.html
```

repository: seborama/enron-bigdata

gha_language: Java

repo_name: seborama/enron-bigdata


text:
# comment.aculo.us

Have you ever wanted to comment on [mir.aculo.us][] blog posts? Me neither. But now, you can!

## Installation

[mainscript]: https://raw.github.com/cowboy/comment.aculo.us/master/dist/commentaculous.js
[userscript]: https://raw.github.com/cowboy/comment.aculo.us/master/dist/commentaculous.user.js
[greasemonkey]: https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/
[mir.aculo.us]: http://mir.aculo.us/

If you're using Firefox, make sure you have the [Greasemonkey][greasemonkey] add-on installed first.

**To install, [click this userscript][userscript], then click Ok/Continue/Install in any browser confirmation dialogs that pop up.** Once installed, reload the [mir.aculo.us][] webpage. If you scroll down, you should see comments.

## What's a Userscript?

 Chrome has native support for userscripts as Extensions, and Firefox supports userscripts via the [Greasemonkey][greasemonkey] add-on.

To manage userscripts:

* In Chrome: Tools > Extensions
* In Firefox: Greasemonkey > Manage User Scripts

## Updating

Once the [userscript][userscript] has been installed, changes to the [main script file][mainscript] will automatically load whenever it's updated. Just reload the [mir.aculo.us][] webpage to get the latest version.

## Contributing
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [grunt](https://github.com/cowboy/grunt).

_Also, please don't edit files in the "dist" subdirectory as they are generated via grunt. You'll find source code in the "src" subdirectory!_

## License
Copyright (c) 2012 "Cowboy" Ben Alman
Licensed under the MIT license.
<http://benalman.com/about/license/>


text:
---
title: "Download Bachna Ae Haseeno (2008) Hindi Movie Bluray || 720p [1GB] || 1080p [4.2GB]"
date: "2020-06-13"
---

Download **Bachna Ae Haseeno** (2008) Hindi Movie in [**720p**](https://1moviesflix.com/720p-movies/) and **[1080p](https://1moviesflix.com/480p-movies/)**. This is a Bollywood Hindi movie and available in **1080p, 720p** quality. This is a  **Comedy, Drama, Romance**  based movie. This movie is released in **2008** in the Hindi language**.** Click on the Download button below to download this movie. This is the Latest **Bluray Print** with **Hindi audio**.

**TheMoviesFlix.in** is one of the Best Websites/Platform For Bollywood and Indian Movies and Series. We also provide south movies like Tamil, Telugu and Malayalam movies, and also Bengali, Punjabi, and other local movies. We Provide Direct Fast Google Drive Download Links For Secure Downloading. Just Click On Download Button And Follow Steps To Download And Watch Movies Online For Free.

[![](https://m.media-amazon.com/images/M/MV5BMjAyNzkyNjAwOF5BMl5BanBnXkFtZTgwNTM1NTYyNTM@._V1_SX300.jpg)](https://www.imdb.com/title/tt1182972/ "Watch Out Ladies")

Watch Out Ladies (2008)

6.2**Rating:** 6.2 / 10 from 10,189 users**Metascore:** N/A

Raj is a heartbreaker. His love stories with Mahi, Radhika and Gayatri finally teach him about love and life in their own sweet, sexy and sassy way.

### Download Bachna Ae Haseeno 2008 720p & 1080p – Full Hindi Movie

### Movie Info:

- **Full Name:** Bachna Ae Haseeno
- **Language:** Hindi
- **Release Year:** 2008
- **Size:** 4.2GB & 1GB
- **Quality:** 1080p & 720p
- **Format:** Mkv
- **Director:** Siddharth Anand
- **Writers:** Aditya Chopra (story), Devika Bhagat
- **Stars:** Ranbir Kapoor, Deepika Padukone, Bipasha Basu

## Storyline:

Why do girls always fall for the wrong guy? Their mothers warn them about him. Their friends shake their heads disapprovingly. Their minds tell them to escape while the going is good. But no! oh no! Their hearts are another story. You see, they are sending all the wrong signals. His name alone is enough to scramble their brains and set their hearts racing.

Meet Raj. He is the stuff of dreams, with the looks of a butter wouldnt melt in my mouth good boy.

Who can blame him for falling in love as many times as love is fortunate enough to find him. Its not his fault that hes a heartbreaker, its in his DNA.

Come discover his three love stories; Raj and Mahi, Raj and Radhika, Raj and Gayatri. Different ladyloves at different times in his life. And each of them, teach him a little bit about love and a little bit about life, in their own sweet, sexy or sassy way.

Come fall in love… three times.

* * *

* * *

.button { color: white; padding: 8px 6px; text-align: center; text-decoration: none; display: inline-block; font-size: 14px; margin: 2px 1px; -webkit-transition-duration: 0.4s; /\* Safari \*/ transition-duration: 0.4s; cursor: pointer; } .button5 { background-color: #555555; color: white; border: 1px solid #e7e7e7; border-radius: 4px; } .button5:hover { background-color: #e7e7e7; border: 2px solid #555555; color: black; } [Join Our Telegram](http://gdrivepro.xyz/join.php) [Hollywood](https://moviesverse.com/) [AnimeFlix](https://animeflix.in/) [Download PC Games](https://gamesflix.net/)

* * *

* * *

Please Do Not Use VPN for Downloading Movies From Our Site.

Click On The Above **Download Button** to Download File.

If You Find Any Broken Link Then **Report** To Us.

**Comment** Your Queries And Requests Below In The Comment Box.

* * *


text:
## Node LSP introspector

Downloads the associated LSP node modules and generates the Ruby
LSP types and enumerations for the Puppet Language, and Debug, Server

### Prerequisites

* NodeJS install (10.0+)

## Generate Types

1. Modify the versions of `vscode-languageserver-protocol` and `vscode-languageserver-types` in the package.json file located at `/tools/lsp_introspect/package.json`.  Note that dependencies must be specified explicitly, do not depend on npm to do that for you.

2. Run `npm install` to download the required node modules

3. Run `node languageprotocol.js` to generate the Language Server ruby types

4. Run `node debugprotocol.js` to generate the Debug Server ruby types

5. Commit the changes and raise a Pull Request

repository: puppetlabs/puppet-editor-services

gha_language: Ruby

repo_name: puppetlabs/puppet-editor-services


text:
# interbotix_xshexapod_gazebo

## Overview
This package contains the necessary config files to get any of the many Interbotix X-Series hexapods working in Gazebo. Specifically, it contains the [interbotix_texture.gazebo](config/interbotix_texture.gazebo) file which allows the black texture of the hexapods to display properly (following the method explained [here](http://answers.gazebosim.org/question/16280/how-to-use-custom-textures-on-urdf-models-in-gazebo/)). It also contains YAML files with tuned PID gains for the hexapod joints so that ros_control can control the hexapods effectively. This package is meant to be used in conjunction with a node that publishes joint positions to the appropriate topics.

## Structure
![xshexapod_gazebo_flowchart](images/xshexapod_gazebo_flowchart.png)
As shown above, the *interbotix_xshexapod_gazebo* package builds on top of the *interbotix_xshexapod_descriptions* and *gazebo_ros* packages. To get familiar with the nodes in the *interbotix_xshexapod_descriptions* package, please look at its README. The other nodes are described below:
- **gzserver** - responsible for running the physics update-loop and sensor data generation
- **gzclient** - provides a nice GUI to visualize the robot simulation
- **controller_manager** - responsible for loading and starting a set of controllers at once, as well as automatically stopping and unloading those same controllers
- **spawn_model** - adds the robot model as defined in the 'robot_description' parameter into the Gazebo world

## Usage
To run this package, type the line below in a terminal (assuming the PhantomX Mark4 is being launched).
```
$ roslaunch interbotix_xshexapod_gazebo xshexapod_gazebo.launch robot_model:=pxmark4
```
Since by default, Gazebo is started in a 'paused' state (this is done to give time for the controllers to kick in), unpause the physics once it is fully loaded by typing:
```
$ rosservice call /gazebo/unpause_physics
```
This is the bare minimum needed to get up and running. Take a look at the table below to see how to further customize with other launch file arguments.

| Argument | Description | Default Value |
| -------- | ----------- | :-----------: |
| robot_model | model type of the Interbotix Hexapod such as 'pxmark4' or 'wxmark4' | "" |
| robot_name | name of the robot (typically equal to `robot_model`, but could be anything) | "$(arg robot_model)" |
| external_urdf_loc | the file path to the custom urdf.xacro file that you would like to include in the Interbotix robot's urdf.xacro file| "" |
| use_rviz | launches Rviz | true |
| rviz_frame | fixed frame in Rviz; this should be changed to `map` or `<robot_name>/odom` if mapping or using local odometry respectively | $(arg robot_name)/base_bottom_link |
| world_name | the file path to the Gazebo 'world' file to load | refer to [xshexapod_gazebo.launch](launch/xshexapod_gazebo.launch) |
| gui | launch the Gazebo GUI | true |
| debug | Start gzserver in debug mode using gdb | false |
| paused | start Gazebo in a paused state | true |
| recording | enable Gazebo state log recording | false |
| use_sim_time | tells ROS nodes asking for time to get the Gazebo-published simulation time, published over the ROS topic /clock | true |
| use_position_controllers | set to true to have the ability to command arbitrary positions to the turret joints in Gazebo | true |


text:
---
title: 'two-sum'
date: '19-06-2020'
---

Given an array of integers, return indices of the two numbers such that they add up to a specific target.

You may assume that each input would have exactly one solution, and you may not use the same element twice.

Example:
Given nums = [2, 7, 11, 15], target = 9,

Because nums[0] + nums[1] = 2 + 7 = 9,
return [0, 1]

Solution:
```js
var twoSum = function(nums, target) {
  // loop through the numbers
    for (let i = 0; i < nums.length; i++) {
      // for each number, check if it's equal to target - the next number
        for (let j = i+1; j <nums.length; j++) {
            if (nums[i] === target - nums[j]) {
                // if yes, then return the two numbers
                return [i, j]
            }
        }
    }
};
```

repository: Aichi-Chang/moodboard

gha_language: CSS

gha_license_id: MIT

repo_name: Aichi-Chang/moodboard


text:
---
layout: layout.pug
beta: true
navigationTitle: Kommander 2.0 Release Notes
title: Kommander 2.0 Release Notes
menuWeight: 0
excerpt: View release-specific information for Kommander 2.0
enterprise: false
---

**D2iQ® Kommander® version 2.0 beta 6 was released on 09, August 2021.**

## Release summary

This release provides new features and enhancements to improve the user experience, fix reported issues, integrate changes from previous releases, and maintain compatibility and support for other packages used in Kommander.

### New features and capabilities

#### Multi-Tenant Logging Architecture

DKP 2.0 Beta Logging is disabled by default. This Beta release contains a new logging architecture implementation and the documentation for manually enabling logging at both the Workspace and Project levels. Logging at the Project-level offers the initial functionality needed for multi-tenant logging. Access the [Logging](../logging) Beta doc pages to review the new architecture and to get started with multi-tenant logging.

#### Unidirectional Network Functionality

#### HTTP Proxy Support

Kommander supports environments where Internet access is restricted, and must be made through an HTTP/HTTPS proxy. In these environments, you can configure Kommander to use the HTTP/HTTPS proxy. In turn, Kommander then configures all platform services to use the HTTP/HTTPS proxy. Refer to this [topic](../install/http-proxy) for more info.

### Component updates

The following services and service components have been upgraded to the listed version:

- centralized-kubecost: 0.16.1
    - cost-analyzer: 1.84.1
    - grafana: 7.5.6
    - prometheus: 2.22.2
    - prometheus alertmanager: 0.20.0
    - thanos: 0.19.0
- cert-manager: 0.2.7
    - cert-manager: 1.0.3
- dex: 2.9.6
    - dex: 2.27.0
- dex-k8s-authenticator: 1.2.8
    - dex-k8s-authenticator: 1.2.2
- external-dns: 2.20.5
    - external-dns: 0.7.0
- fluent-bit: 0.16.2
    - fluentbit: 1.8.3
- gatekeeper: 0.6.8
    - gatekeeper: v3.4.0-rc.1
- grafana-logging: 6.13.9
    - grafana: 8.0.5
- grafana-loki: 0.33.1
    - loki: 2.2.1
- istio: 1.9.1
    - istio: 1.9.1
- jaeger: 2.21.0
    - jaeger: 1.21.2
- karma: 2.0.0
    - karma: 0.88
- kiali: 1.29.0
    - kiali: 1.29.0
- kube-oidc-proxy: 0.2.5
    - kube-oidc-proxy: 0.2.0
- kube-prometheus-stack: 16.13.1
    - grafana: 8.0.5
    - prometheus: 2.27.1
    - prometheus alertmanager: 0.22.2
    - thanos: 0.17.2
- kubecost: 0.16.1
    - cost-analyzer: 1.84.1
    - grafana: 7.5.6
    - prometheus: 2.22.2
    - prometheus alertmanager: 0.20.0
    - thanos: 0.19.0
- kubefed: 0.8.1
    - kubefed: 0.8.1
- kubernetes-dashboard: 4.0.3
    - kubernetes-dashboard: 2.2.0
- kubetunnel: 0.0.7
    - kubetunnel: 0.0.7
- logging-operator: 3.13.0
    - logging-operator: 3.13.0
- metallb: 0.12.2
    - metallb: 0.9.3
- minio-operator: 4.1.7
    - minio-operator: 4.1.3
- nvidia: 0.4.0
    - nvidia driver version: 460.73.01
- project-grafana-logging: 6.13.9
    - grafana: 8.0.5
- project-grafana-loki: 0.33.1
    - loki: 2.2.1
- project-logging: 1.0.0
- prometheus-adapter: 2.11.1
    - prometheus-adapter: 0.8.3
- reloader: 0.0.85
    - reloader: 0.0.85
- thanos: 0.3.31
    - thanos: 0.17.1
- traefik: 9.19.1
    - traefik: 2.4.8
- traefik-forward-auth: 0.3.1
    - traefik-forward-auth: 3.0.1
- velero: 3.1.3
    - velero: 1.5.2

### Known Issues

- The Traefik dashboard is currently not exposed. To access the dashboard, port-forward the service with the following command.

  On the management cluster, replace `<type_your_workspace_name>` with `kommander`, otherwise for attached clusters replace it with the name of the workspace that Traefik is deployed to:

  ```bash
  export WORKSPACE_NAMESPACE=$(kubectl get workspace <type_your_workspace_name> -o jsonpath='{.spec.status.namespaceRef.name}')
  kubectl port-forward -n ${WORKSPACE_NAMESPACE} svc/kommander-traefik-dashboard 9000:80
  ```

  You can access the dashboard in your browser at `http://localhost:9000/dashboard/` (the trailing `/` is required).

### Additional resources

For information about working with native Kubernetes, see the [Kubernetes documentation][kubernetes-doc].

[kubernetes-doc]: https://kubernetes.io/docs/home/

repository: shaunstoltz/dcos-docs-site

repo_name: shaunstoltz/dcos-docs-site


text:
---
layout: default
---

# 1998-09-28 - Re: Remailers, PGP, and a Project Suggestion

## Header Data

From: Anonymous<EMAIL_ADDRESS>To<EMAIL_ADDRESS>Message Hash: ba71aaaf8405e0b7fffe25a73d56f7d5394b201ab360fc893712086ea38dea4d

Message ID<EMAIL_ADDRESS>Reply To: _N/A_

UTC Datetime: 1998-09-28 16:05:08 UTC

Raw Date: Tue, 29 Sep 1998 00:05:08 +0800

## Raw message

```
{% raw  %}From: Anonymous<EMAIL_ADDRESS>Date: Tue, 29 Sep 1998 00:05:08 +0800
To<EMAIL_ADDRESS>Subject: Re: Remailers, PGP, and a Project Suggestion
Message-ID<EMAIL_ADDRESS>MIME-Version: 1.0
Content-Type: text/plain

>        So, what you are saying is that you want crypto to protect yourself
>from government intrusion, but are unwilling to actually WRITE the code for
>fear that the government will lock you up.

That's about right. I will write the code for myself. I will not release it
since I'm in the U.S. and it gives the thugs one more reason to come after
me. That job is better suited for somebody who is outside the U.S. or is
actually willing to sit through a long grand jury investigation, possible
indictment, trial, conviction, jail time, and life as a convicted felon.

{% endraw %}
```

## Thread

+ Return to [September 1998](/archive/1998/09)

+ Return to "[Adam Back <aba@dcs.ex.ac.uk>](/authors/adam_back_aba_at_dcs_ex_ac_uk_)"
+ Return to "[Anonymous <nobody@remailer.ch>](/authors/anonymous_nobody_at_remailer_ch_)"
+ Return to "[Petro <petro@playboy.com>](/authors/petro_petro_at_playboy_com_)"
+ Return to "[phelix@vallnet.com](/authors/phelix_at_vallnet_com)"

+ 1998-09-28 (Tue, 29 Sep 1998 00:05:08 +0800) - Re: Remailers, PGP, and a Project Suggestion - _Anonymous<EMAIL_ADDRESS>  + 1998-09-28 (Tue, 29 Sep 1998 07:05:12 +0800) - [Re: Remailers, PGP, and a Project Suggestion](/archive/1998/09/810f1c045e46e4deb17aa2ae2edcdcc469eea5597c04f9e2c8500c2a66df9558) - _Adam Back<EMAIL_ADDRESS>  + 1998-09-29 (Tue, 29 Sep 1998 12:36:01 +0800) - [Re: Remailers, PGP, and a Project Suggestion](/archive/1998/09/571134f919e1dcb7d4dc52e045f6c1772aaf8b01ec36221857ee3e5bf27730fa) - _Petro<EMAIL_ADDRESS>  + 1998-09-29 (Tue, 29 Sep 1998 19:56:13 +0800) - [Re: Remailers, PGP, and a Project Suggestion](/archive/1998/09/026320ac46e9db9499098b670bf94275cf2515c6ceca31267bdf1522d22d3c77) -<EMAIL_ADDRESS>


text:
# auto-camp
Chrome extension to auto-play albums from Bandcamp

Currently it has the functionality to scrape the song duration information and HTML objects to play songs from the BandCamp site, and
play through the entire album automatically. It also has basic media player tools such as pausing/resuming and skipping and resuming
songs.

The latest update uses React to render the elements and added new functionality including:

A track list from which you can choose songs
Song title, artist name, and album info for current music

Feel free to port this over to other browsers if you would like, but just list me in the credits :)

license: Unlicense

gha_language: JavaScript


text:
# example-resume

An example resume, built with GitHub Pages.

Managing your resume with git, Markdown, and [GitHub Pages](https://pages.github.com/) is good because it's:

 - **Easy to read** because the formatting is simple.
 - **Version controlled** because it's git.
 - **Easy to edit** because it's Markdown.
 - **Convertable to PDF** by printing it your browser.

The [final product](https://auxesis.github.io/example-resume) is HTML.

Get started with Jekyll locally
-------------------------------

Ensure you have git, Ruby, and Bundler installed, then:

``` bash
git clone https://github.com/auxesis/example-resume.git
cd example-resume
bundle
```

Edit `index.markdown`, then build with:

```
bundle exec jekyll serve --watch
```

Then [view the resume](http://localhost:4000/) locally.

There are three parts to the resume
-----------------------------------

 1. `index.markdown` is the resume.
 2. `_layouts/resume.html` is the layout.
 3. `stylesheets/resume.css` in the stylesheet.

Unless you want to change the presentation significantly, just edit the resume in `index.markdown`.

Then you make it your own
-------------------------

When you're ready to make the resume your own, [create a new repo](https://github.com/new), enable [GitHub Pages](https://help.github.com/articles/configuring-a-publishing-source-for-github-pages/) (just use `master` as it's the simplest), then push:

``` bash
git push origin master
```

repository: auxesis/example-resume

repo_name: auxesis/example-resume


text:
# Postman Monitor with Prometheus

This project provides a small Node.js based server which will run a Postman collection continuously on regular interval. It uses the Newman library that Postman provides, and exposes various HTTP and request metrics and stats in Prometheus exposition format so they can be scraped by Prometheus. This allows you to proactively monitor any Postman collection you wish, from wherever you wish.

You can use this to monitor the health and performance of web sites and REST APIs, and by using test assertions (see below) you can validate the contents returned, status codes, headers etc. Even chain requests together extracting variables from one request to use with another.

By default the server listens on port 8080 and provides metrics at the standard `/metrics` endpoint. The collection you want to run can be fetched by the runner at startup from a URL you supply, or you can build the runner container with the collection file copied into the image.

The server is containerised and published publicly at ghcr.io/benc-uk/postman-prometheus

Kubernetes manifests for deployment are also provided.

Goals:

- Turn Postman into a continuous monitoring tool
- Export Postman/Newman data into Prometheus

Use cases & key features:

- Monitoring of APIs and websites
- Go beyond simple single HTTP checks, using Postman's [collection feature](https://learning.postman.com/docs/running-collections/intro-to-collection-runs/) and [test assertions](https://learning.postman.com/docs/writing-scripts/script-references/test-examples/) for checking and chaining

![](https://img.shields.io/github/license/benc-uk/postman-prometheus)
![](https://img.shields.io/github/last-commit/benc-uk/postman-prometheus)
![](https://img.shields.io/github/release/benc-uk/postman-prometheus)
![](https://img.shields.io/github/checks-status/benc-uk/postman-prometheus/main)

# Example

This is a screenshot of the provided Grafana dashboard

The dashboard can be found in the [grafana directory](https://github.com/benc-uk/postman-prometheus/tree/main/grafana) as a JSON file which you can import.

![screen shot of dashboard](https://user-images.githubusercontent.com/14982936/111913204-fd8a6400-8a64-11eb-95c1-a40f4828d05f.png)

# Config

| Environmental Variable | Purpose                                                          | Default           |
| ---------------------- | ---------------------------------------------------------------- | ----------------- |
| PORT                   | Port the server listens on                                       | 8080              |
| COLLECTION_FILE        | Path to Postman collection file to load and use                  | ./collection.json |
| COLLECTION_URL         | Load from Postman collection from URL, overrides COLLECTION_FILE | _none_            |
| RUN_INTERVAL           | How frequently to run the collection, in seconds                 | 30                |
| RUN_ITERATIONS         | How many iterations of the collection to run                     | 1                 |
| ENABLE_BAIL            | Stops the run when a test case or request fails                  | false             |
| ENABLE_REQUEST_METRICS | Disable the per-request metrics if you wish                      | true              |
| ENVIRONMENT_FILE       | Path to a Postman environment file                               | _none_            |
| ENVIRONMENT_URL        | Load a Postman environment from URL, overrides ENVIRONMENT_FILE  | _none_            |
| POSTMAN\_{varname}     | Environment vars to pass to running the collection               | _none_            |

## Note on Postman variables

Postman/Newman can [accept variables a number of ways](https://learning.postman.com/docs/sending-requests/variables/) with this runner you supply values for any variables your scripts reference in two ways:

- Environments file, created by defining an environment in Postman and [exporting as JSON](https://learning.postman.com/docs/getting-started/importing-and-exporting-data/#exporting-environments)
- Using special `POSTMAN_{varname}` environment vars, set as regular OS environment vars (therefor settable at runtime from Docker and Kubernetes). The prefix `POSTMAN_` is required and stripped off, leaving the name of the variable to set when running the collection, e.g. if your Postman request referenced a variable `{{myvar}}` you can set it using `POSTMAN_myvar=foo`

# Repo Contents

📁 `src` - Source of the Node.js runner which wraps Newman
📁 `samples` - Example Postman collections for monitoring
📁 `grafana` - Example Grafana dashboard which can be imported
📁 `deploy` - Deployment to Kubernetes, plus Helm samples for alerting
📁 `build` - Dockerfile mostly
📁 `scripts` - Some bash scripts

# Using

Just about everything you need to do with this project has been put into make

```txt
$ make

help                 💬 This help message
run                  🥈 Run locally (requires Node.js)
image                🔨 Build container image from Dockerfile
lint-fix             📜 Lint & format, will try to fix errors and modify code
lint                 🔎 Lint & format, will not fix but sets exit code on error
push                 📤 Push container image to registry
deploy               🚀 Deploy to Kubernetes
undeploy             💀 Remove from Kubernetes
```

The `deploy` target provides a lightweight "Helm-less" way to deploy to Kubernetes, using envsubst, makefile variables and deploy/deployment.yaml as a template.
Before running `make deploy` check the `DEPLOY_` variables in the makefile, then either edit or override these

# Exported Metrics

Below is a dump of all the metrics the server will export.

> **💬 Note**. There could be MANY per-request metrics, if running a collection with a large number of requests and a large number of iterations. You have been warned!

```txt
# ==========================================================
# Lifetime metrics for the whole life of the monitor server
# ==========================================================

# TYPE postman_lifetime_runs_total counter
postman_lifetime_runs_total{collection="Example"} 69

# TYPE postman_lifetime_iterations_total counter
postman_lifetime_iterations_total{collection="Example"} 138

# TYPE postman_lifetime_requests_total counter
postman_lifetime_requests_total{collection="Example"} 276

# ==========================================================
# Metrics aggregated for the whole collection
# ==========================================================

# TYPE postman_stats_iterations_total gauge
postman_stats_iterations_total{collection="Example"} 2

# TYPE postman_stats_iterations_failed gauge
postman_stats_iterations_failed{collection="Example"} 0

# TYPE postman_stats_requests_total gauge
postman_stats_requests_total{collection="Example"} 4

# TYPE postman_stats_requests_failed gauge
postman_stats_requests_failed{collection="Example"} 0

# TYPE postman_stats_tests_total gauge
postman_stats_tests_total{collection="Example"} 4

# TYPE postman_stats_tests_failed gauge
postman_stats_tests_failed{collection="Example"} 0

# TYPE postman_stats_test_scripts_total gauge
postman_stats_test_scripts_total{collection="Example"} 4

# TYPE postman_stats_test_scripts_failed gauge
postman_stats_test_scripts_failed{collection="Example"} 0

# TYPE postman_stats_assertions_total gauge
postman_stats_assertions_total{collection="Example"} 8

# TYPE postman_stats_assertions_failed gauge
postman_stats_assertions_failed{collection="Example"} 2

# TYPE postman_stats_transfered_bytes_total gauge
postman_stats_transfered_bytes_total{collection="Example"} 43750

# TYPE postman_stats_resp_avg gauge
postman_stats_resp_avg{collection="Example"} 40.25

# TYPE postman_stats_resp_min gauge
postman_stats_resp_min{collection="Example"} 17

# TYPE postman_stats_resp_max gauge
postman_stats_resp_max{collection="Example"} 107

# ==========================================================
# These metrics are per request AND per iteration
# ==========================================================

# TYPE postman_request_status_code gauge
postman_request_status_code{request_name="Some Example Request",iteration="0",collection="Example"} 200

# TYPE postman_request_resp_time gauge
postman_request_resp_time{request_name="Some Example Request",iteration="0",collection="Example"} 19

# TYPE postman_request_resp_size gauge
postman_request_resp_size{request_name="Some Example Request",iteration="0",collection="Example"} 8684

# TYPE postman_request_status_ok gauge
postman_request_status_ok{request_name="Some Example Request",iteration="0",collection="Example"} 1

# TYPE postman_request_failed_assertions gauge
postman_request_failed_assertions{request_name="Some Example Request",iteration="0",collection="Example"} 0

# TYPE postman_request_total_assertions gauge
postman_request_total_assertions{request_name="Some Example Request",iteration="0",collection="Example"} 3
```


text:
---
title: "Monitor the Application"
chapter: true
weight: 40
---

# Monitor the Application on Kubernetes

### Welcome

### Learning Objectives

- Update the Datadog Agent Helm Chart
- Understand whats different about monitoring an application on Kubernetes.

{{% notice warning %}}
<p style='text-align: left;'>
The examples and sample code provided in this workshop are intended to be consumed as instructional content.
These will help you understand how various cloud services can be used to build a solution while demonstrating best
practices along the way. These examples are not intended for use in production environments.
</p>
{{% /notice %}}


text:
# PROJECT MOVED

New project is hosted on GitLab: https://gitlab.com/project-deadlock/embedded-fw-build-image

# embedded-fw-build-image
Docker image with installed tools for building and testing embedded firmware for components of project Deadlock


text:
# Ecommerce-clothing-recommendation-prediction

**Goal : Predicting Ecommerce cloth Recommendation & Analyzing the reviews**

**Dataset** : [Kaggle women ecommerce clothing review](https://www.kaggle.com/nicapotato/womens-ecommerce-clothing-reviews)

## Motivation

1. Suggesting the business to significant words for recommended products
2. Suggesting the business to important categories and influencing factors in recommendedation
3. What kind of categories people have more negative reviews and what are they try to say
4. Correlation between Negative review and Recommendation

## Methodology

0. **`Sentiment Analysis`** -  Finding the sentiments for reviews using lexical sentiment analysis approach.

- Determine the approch - [Sentiment-analysis-tools-overview](https://medium.com/@datamonsters/sentiment-analysis-tools-overview-part-1-positive-and-negative-words-databases-ae35431a470c), [TextBlob](https://textblob.readthedocs.io/en/dev/)
- Find a way to validate
- Find correlation between sentiment result and postitive count feature

1. **`Suggesting the business to significant words for recommended products`** - using TF-IDF in review extraction, building categorical model with reviews to predict recommendation then finding more weighted words.

- Experiment with the different models and validate (Make sure model results are interpretable).

2. **`Suggesting the business to important categories and influencing factors in recommendedation`** - using bag of words in product categories, building categorical model with reviews to predict recommendation then finding more weighted categories.

- Experiment with the different models and validate (Make sure model results are interpretable).

3. **`What kind of categories people have more negative reviews and what are they try to say`** - Filter top TF-IDF in negative sentence and Experiment with topic modeling

4. **`Correlation between positive review and Recommendation`** - using TF-IDF in positive review extraction, building categorical model with reviews to predict recommendation then finding more weighted words.

*Optional : using Words embedding to combine the features [keras]*

## Aim for each phase

- **Data Analysis :** Experiment our Business hypothesis with dataset. Find the pattens in dataset. Plan for Feature Engineering.
- **Data Preprocess :** Based on insights, start with preprocessing. Apply all regular NLP feature engineering (Tokens, stemming, lower letter and trimming). Apply TF-IDF & Bag of words for each words
- **Model Building & Validation :** Apply all possible models and validate with that. Validate with Cross matrix initially. It is efficient and easy to interpret more metrics.
- **Business Inference :** Try to interpret the results from modelt result. for `objective 3` , use topic modelling and extract the topics.

## Plan

| SI No | Plan Date | Topic                                                | Start date | End date | Status | User            |
| ----- | --------- | ---------------------------------------------------- | ---------- | -------- | ------ | --------------- |
| 1     | 09.07     | Get insights of data & Better Business understanding |            |          | YTS    | Balaji          |
| 2     | 09.07     | Get insights of data & Better Business understanding |            |          | YTS    | Karuna          |
| 3     | 09.07     | Discuss about insights                               |            |          | YTS    | Balaji & Karuna |
| 3     | 10.07     | Plan for preprocessing & Model selection             |            |          | YTS    | Balaji & Karuna |
| 4     | 30.07     | Feature Engineering 1                                |            |          | YTS    | Balaji          |
| 8     | 30.07     | Feature Engineering 1                                |            |          | YTS    | Karuna          |
| 5     | 30.07     | Discussion and planning                              |            |          | YTS    | Balaji & Karuna |
| 6     | 16.08     | Feature Engineering 2                                |            |          | YTS    | Karuna          |
| 7     | 16.08     | Feature Engineering 2                                |            |          | YTS    | Balaji          |
| 8     | 16.08     | Discussion and planning                              |            |          | YTS    | Balaji & Karuna |
| 9     | 19.08     | Apply all models                                     |            |          | YTS    | Balaji          |
| 10    | 19.08     | Apply all models                                     |            |          | YTS    | Karuna          |
| 11    | 19.08     | Discussion and planning                              |            |          | YTS    | Balaji & Karuna |
| 12    | 22.08     | Validating the models                                |            |          | YTS    | Balaji          |
| 13    | 22.08     | Validating the models                                |            |          | YTS    | Karuna          |
| 14    | 22.08     | Discussion and planning                              |            |          | YTS    | Balaji & Karuna |
| 15    | 24.08     | Buissness  inference                                 |            |          | YTS    | Balaji          |
| 16    | 24.08     | Buissness  inference                                 |            |          | YTS    | Karuna          |
| 17    | 24.08     | Discussion and planning                              |            |          | YTS    | Balaji & Karuna |


text:
Description
===========
Installs and configures PostgreSQL streaming replication using the EnterpriseDB installer in unattended mode. Additionally:
* Configures for hotbackups and schedules on the cron
* Creates a .psqlrc with some utility alias queries
* Inserts some utility scripts into a DBA directory that assist in the creation of databases and users etc...

Requirements
============

## Platforms

* Red Hat/Centos/Fedora

Tested on:

* Centos 6.5

ToDo
====
* Add support for Debian/Ubuntu and test.

Attributes
==========
See the `attributes/default.rb` file for default values.

System level parameters
-----------------------
* `node['postgresql']['version']` - Major version of PostgreSQL to manage.
* `node['postgresql']['port']` - Port PostgreSQL will listen on.
* `node['postgresql']['pguser']` - User PostgreSQL will be installed as.
* `node['postgresql']['bkuser]` - PostgreSQL backup user with replication privs.
* `node['postgresql']['bin_mount']` - Location of the PostgreSQL binaries.
* `node['postgresql']['data_mount']` - Location of the PostgreSQL data dir.
* `node['postgresql']['bak_mount']` - Location of the PostgreSQL backups.
* `node['postgresql']['pg_media']` - Name of installation executable.

Configuration parameters
------------------------
The `postgresql.conf` file is dynamically generated from the attributes in the `attributes/default.rb` file. Edit these to ensure the desired database parameteres are set.

Usage
=====
Just include `postgresql` in your node's `run_list`:

From Vagrant - I have the following in my Vagrantfile:

Vagrant.configure(2) do |config|
  (1..2).each do |i|
	  config.vm.define "node#{i}" do |node|

  		node.vm.box = "chef/centos-6.5"

		node.vm.provider "virtualbox" do |vb|
		     vb.memory = "4096"
   		end

		node.vm.hostname = "pgserv0#{i}"
		node.vm.network "private_network", ip: "<IP_ADDRESS>#{i}"

		if i == 1
			node.vm.provision :chef_solo do |chef|
				chef.json = {
					:postgresql => {
						:status  => "master",
						:host1   => "pgserv01",
						:host1ip => "<IP_ADDRESS>",
						:host2   => "pgserv02",
						:host2ip => "<IP_ADDRESS>"
					}
				}
				chef.add_recipe "postgresql-stream-rep"
			end
		end
		if i == 2
			node.vm.provision :chef_solo do |chef|
				chef.json = {
					:postgresql => {
						:status  => "slave",
						:host1   => "pgserv01",
						:host1ip => "<IP_ADDRESS>",
						:host2   => "pgserv02",
						:host2ip => "<IP_ADDRESS>"
					}
				}
				chef.add_recipe "postgresql-stream-rep"
			end
		end
	  end
  end
end

License and Author
==================
- Author:: Steve Bennett<EMAIL_ADDRESS>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

repository: ONSdigital/chef-cookbooks

repo_name: ONSdigital/chef-cookbooks


text:
# Capture or details request on eCom v2 transactions
Requires the programming language [Go](https://golang.org/)

To run a capture batch in production

`go run main.go -config config.json -orders orders.txt -capture -production`

To run in test simply omit "-production"

To run detail requests on a batch of orders

`go run main.go -config config.json -orders orders.txt -detail -production`

`conf.json` and `orders.txt` need to either be filled in or you can refer to some other file above.

Running program without any arguments will give you the list of parameters available

## Input
### Orders input
The order input _must_ be filled with a single OrderID and the amount to be captured per line.

Regardless of if you wish to perform a details request or a capture on the orders.

*If you only wish to perform a details request just fill in 0*
```
OrderID;CaptureAmount
Woo123;0
Woo200;5000
```
**Note** The amount captured should be an integer and "øre" (cent in EUR/USD) in case of NOK.

Thus "NOK 50,95" would written as 5095 and NOK 50,- would be 5000.

**0 means "capture everything"**

### Configuration file
You'll find the required information for this file in the developer portal.

See: [Getting started](https://github.com/vippsas/vipps-developers/blob/master/vipps-getting-started.md) for help on getting started with the developer portal.

## Production & Test
Specify if you wish to run in the production environment by adding `-production` as an argument on the command line.

If you don't specify `-production`, the tool will default to the Merchant Test (MT) environment.

## Tips & tricks
Since you can specify the config file as a parameter you can create multiple config files like this:
`conf.SaleUnitName.json` if you have multiple sale units.

That way you don't need to re-edit the same config file if you have multiple sale units you need to capture and/or perform details requests on.

This of course also works for the order input, i.e.
`orders_SaleUnitName.txt`

The .gitignore file for this particular directory is setup to ignore orders_\*.txt and conf.\*.json

repository: mohbadar/vipps-developers

repo_name: mohbadar/vipps-developers


text:
# WARNING
- this is a super WIP document, do not read it verbatim
- these are Peter's various thoughts, taken from YAML and converted to Markdown

# Features:

## Generic Scene Saving and Loading:

## Scene Relationships:
- Parents
- Children

## Procedural UI Generation:

### Node Distance:
- use a circle

### Node Direction:
- use a vector

### Node Redraws:
- Add/Remove Nodes

### Node Color:
- Choose from palette?
- rand?

### Node Paths:
- line segments

### Node Highlights:
- Show selection

## Navigation:
- zoom in/out
- panning
- pointing/indicating
- juicy movement

## Juice:
- laggy camera/bounce/sway/drift
- every movement tweened
- visual starfield/reactive background/parallax
- light up paths

## Effects:
- arrange scene screenshots along path
- zoom in/out of scene screenshots on load/escape

## Sound/Music:
- System Shock 2 Command 3
- Natural Selection Ambient
- System Shock Cyberspace Arranged

# Saving Techniques:

## Differences:
- saving entire scene change after change?
- saving actions taken in scene? (Logical/JSON)

## Snapshots:
- save entire scene?
- save logical state (Logical/JSON)?

## Master Saves:
- Use Logical Saves (Logical/JSON) with Master Save (Scene)
- Apply logical state to master scene

# Architecture of Time Tree:

## Recursion:
- Time Trees within Time Tree?
- Maybe not great idea
- do save-scenes then have their own time-trees?

# Crazy Ideas:

## Move View not Player:
- we are *choosing* where to go first
- then we have the player move along the path to do so
- or force player to move up/down tree to get to target location
- or "bind" player to the "track"
- make them have to move to where they want to go
- or maybe limit how far they can look

## Alter Music:
- moving forward in time: play normally
- moving backward in time: play backward
- stopped: silence/slow
- see this:
  - title:  Added pitch scale property to AudioStreamPlayer, AudioStreamPlayer2D and AudioStreamPlayer3D
    url:    https://github.com/godotengine/godot/pull/15254
  - title:  Sound FX and Music -- Godot 3 Tutorial Series
    url:    https://www.youtube.com/watch?v=S-8IcHucSNg

## Tweened Camera and Player:
```yaml
- title:      Godot Tween Tutorial
  url:        https://www.youtube.com/watch?v=pFR4DCUeNHo
  status:     INC
  relevance:  unk

- title:      Improved Movement In Godot With Tween Nodes
  url:        https://www.youtube.com/watch?v=DvOe-RlomD0
  status:     INC
  relevance:  HIGH

- title:      "Godot Game Juice Tutorial 1: Camera Shake and Frame Freeze"
  url:        https://www.youtube.com/watch?v=AobjNjzZhmo
  status:     INC
  relevance:  HIGH

- title:      How to Improve Your Camera for Platformers in Godot 3.1
  url:        https://www.youtube.com/watch?v=sxtC7hj2ABY
  status:     INC
  relevance:  HIGH

- title:      How to Make Juicy Camera Shake in Godot with OpenSimplexNoise
  url:        https://www.youtube.com/watch?v=i2A5diEmX6w
  status:     INC
  relevance:  HIGH

- title:      "Godot Game Juice Tutorial 2: Tweening and Particles"
  url:        https://www.youtube.com/watch?v=-MQHFcHegOk
  status:     INC
  relevance:  HIGH
```

# Questions:

## How Should things be saved?:

### Per Scene?:
- each scene remembers its children and its parents

### Per Graph?:
- Graph of all scenes is saved

## What should be saved?:
- Scene Files?
- Resource Files?
- Custom JSON?

## How should we reference?:

### Folder-Names:
- Where to find the tree
- unnecessary

### File-Names:
- Where to find in the folder
- use this
- assumes root name

### Scene-Names:

### Root-Names:
- Name of Root Object to target and load

# Notes:

## Godot Videos:
```yaml
- title:  Experiments with Procedural Graphics in Godot
  url:    https://www.youtube.com/watch?v=KB9jHh2qKlc
  status: NONE
  notes:  [FX]

- title:  How to make better games using Curves in Godot | Game Dev Tutorial 6
  url:    https://www.youtube.com/watch?v=gHT3jsCEiyA
  status: NONE
  notes:  [JUICE]

- title:  "Platform movement in Godot: RigidBody2D vs KinematicBody2D tutorial"
  url:    https://www.youtube.com/watch?v=pnBioV2HkS8
  status: NONE
  notes:  [MOVE]

- title:  How I Implemented A Railway System in Godot
  url:    https://www.youtube.com/watch?v=co2CON-WPPQ
  status: NONE
  notes:  [MOVE]

- title:  How to switch scene using door (portal)? Godot 3 tutorial
  url:    https://www.youtube.com/watch?v=AxymjihpUi4
  status: NONE
  notes:  [SAVE, LOAD]

- title:  How to use light2d to hide a character in shadow because it's ugly. Godot lighting 2d tutorial
  url:    https://www.youtube.com/watch?v=mMFtS6GnLF4&list=PLcgIj8qYyWnEuQUsIu3oP4Ilxbn1ABDHm&index=6
  status: NONE
  notes:  [FX]
```

## Rails Movement:
- Dont use path2d
- Use coordinates
- Use agent
- Capture player inout
- Store as intentional vector
- Compare vector to possible directions
- Move towards available targets
- Scenes saves as targets
- Available targets from possible states and originating state

## Drawing:
- Dont use canvas
- Use StaticBody2D
- Use Circle Radius
- Use Direction Vector
- Use Random Color

## Movement:
- Space (Hold): Start Time Travel (Zoom In)
- Enter (Hold): Choose Target (Zoom In)
- Wasd: Pan/Direction

## Choosing Direction:
- Have Circle Radius around every target
- While in radius, set direction out
- Play loose with player effect

## Lighting along path:
- Make it spooky

## Time Travel Music:
- think Cyberspace from System Shock
- Esp. with the new System Shock Selected Midi
- Maybe slowed down and quieted System Shock 2 tracks?:
  - System Shock 2 Operations deck (slow): https://www.youtube.com/watch?v=-ebbabJBALw
- I envision a dark, dark, dark place
- that the place without space
- and lines without times
- is but cold, shimmering, glittering darkness
- against the bright lines of time
- but exiting those lines
- one shatters the lines, slight
- and pollutes the silence with noise
- the cold, haunting, echoing tune of time
- a clock, grind
- an overwhelming mechanic grind, assured, calm, absolute
- themes:
  - System Shock 2 - Command 3 (Remaster): https://www.youtube.com/watch?v=mFTeyFo07q0
  - too techno
  - System Shock 2 OST - Command 3: https://www.youtube.com/watch?v=YcaQaoqJ5vs
  - the original. much better.
  - hurts to listen to slowed down
  - some really heavy distortion. shame.

## System Shock Minigames:
- Note these are needed to open doors/deactivate traps, etc

## System Shock Life System:
- Saves/Load, Restore Stations
- can become corrupted

## Certain Music Video:
- See Video/Time as 3D shape unfolding

## Train Tracks:
- "godot roller coaster"
- because we will be moving *along* the tree...
- anything with "tracks"
- "move along path"
- "path follower"
- "unity train game"

## Proc Gen:
```yaml
- title:  "Procedural Generation in Godot - Part 7: Dungeons (part 2)"
  url:    http://kidscancode.org/blog/2018/12/godot3_procgen7/
  status: INC

- title:  "Procedural Generation in Godot - Part 2: Using Mazes"
  url:    https://kidscancode.org/blog/2018/09/godot3_procgen2/
  status: INC

- title:  Fractal Trees - L-System
  url:    https://www.reddit.com/r/godot/comments/8t7jo1/fractal_trees_lsystem/
  status: INC

- title:  Godot-L-System-Fractal-Trees
  url:    https://github.com/tofoz/Godot-L-System-Fractal-Trees
  status: INC

- title:  "Code that: L-System"
  url:    https://www.youtube.com/watch?v=eY9XkJERiG0
  status: INC

- title:  forest
  url:    https://github.com/Terkwood/forest
  status: INC

- title:  Making trees
  url:    https://docs.godotengine.org/en/stable/tutorials/content/making_trees.html
  status: INC

- title:  L System Example
  url:    https://roelofgielen.com/portfolio/l-system/
  status: INC

- title:
  url:    https://jsantell.com/l-systems/
  status: INC

- title:
  url:    https://www.reddit.com/r/godot/comments/hvy1cr/procedural_tree_generation_using_lsystems/
  status: INC

- title:
  url:    https://github.com/topics/lindenmayer-systems
  status: INC

- title:
  url:    https://github.com/dilmerv/UnityLSystemEssentials
  status: INC
```

# Game Design:
```yaml
- title:  The Fidget Factor | Yahtzee's Dev Diary | S2 EP 10
  url:    https://www.youtube.com/watch?v=mk_rHekhJaI
  status: watched
  type:   [game-dev, talk]
  policy: public
  notes:
  - Very useful, how to make travel actual, and not just "a thing that happens"
  - make it more involved
  - compare to time travel?
  - make analogy of time-travel = space-travel
  - note use of small mechanics to reinforce major mechanics

- title:  "Ross's Game Dungeon: Clans"
  url:    https://www.youtube.com/watch?v=QHYH0jFMWSY
  status: watched
  type:   [game, review]
  policy: public
  notes:
  - Excellent breakdown of a bad game
  - Pass on to Cosmic Engine
  - talk about grind, time travel and differentiating from Save Scumming
  - Talk about adding Quality of Life enhancements to make the game better between saves
  - (Essentially, pursue a Prey (2017) style of saves, that arent total)
  - ((Idea is, some stuff saved separately, allow avoiding repeated content))
```

# misc:
```yaml
- title:  Arrow Symbols
  url:    https://unicode-table.com/en/sets/arrow-symbols/
  notes:
  - handy for documentation purposes

- title:  GDScript exports
  url:    https://docs.godotengine.org/en/stable/getting_started/scripting/gdscript/gdscript_exports.html
  notes:
  - use these!!!!!

- title:  List of export hints
  url:    https://godotengine.org/qa/6099/list-of-export-hints

- title:  How to raise an error with a message?
  url:    https://godotengine.org/qa/29525/how-to-raise-an-error-with-a-message
  notes:
  - push_error("message")
  - push_warning("message")
  - assert(condition, "message")

- title:  Git Overwrite master with branch
  url:    https://stackoverflow.com/questions/30105210/git-overwrite-master-with-branch

- title:    My character and toon shader are now starting to come along! (more details in comments)
  url:      https://www.reddit.com/r/godot/comments/jpkcox/my_character_and_toon_shader_are_now_starting_to/
  status:   INC
  notes:
  - its a guide, complete with code and shader-graph

- title:    Keeping my objective of using godot as an art framework
  url:      https://www.reddit.com/r/godot/comments/jpf3zj/keeping_my_objective_of_using_godot_as_an_art/
  notes:
  - use this for drawing the time-tree!
  - it looks pretty!

- title:    How to properly navigate Godots Scene tree programmatically
  url:      https://www.reddit.com/r/godot/comments/bwe5i4/how_to_properly_navigate_godots_scene_tree/
  notes:
  - handy for others, esp non-coders as to why some things arent working
```

# chrono elements:

## chrono-trigger:
- listens for whether the user wants to go to the tree or not
- isolates it from any other interface

## chrono-tree:
- displays all connected scenes
- can go to a particular scene from here

## chrono-logger:
- saves the scene as the user plays through it
- also holds scene relationship info
- assumes we are saving a new scene EACH TIME
- should have some sort of ACTIONS which it TRACKS
- or else actions which need to be recorded should EMIT a SIGNAL
- for clarity's sake, probably best to keep this separate from chrono-trigger

## question:
- will trigger and logger ever be exculsive?
- or must one always be with the other?
- it may be better to just comine them into one object

# saving:

## scenes:
- currently my "test.tscn" has 9,900 characters and is 10 KB in size
- an average scene might be... 50 KB at smallest
- thats 20 saves per 1 MB
- we are looking at A LOT of saves... say 300
- 300 * 50 = 15 MB of storage
- alternatively, we could try using some LOGICAL representation of the game state
- such as a TRES
- or objects could self-report what is important

## connections:
- we could have some master file of all the connections between scenes
- each scene could have some object to represent its children
- or its parent
- but this requires the chrono-tree to open EACH SAVE to build the full tree
- this could take a long time!
- is better if chrono-tree keeps track of relationships
- it should get updated each time a new scene is created

## resources:
```yaml
- title:    "Godot: How to save Game Progress in a Single Resource File"
  url:      https://www.youtube.com/watch?v=ldKFOGRQDzo
  status:   done
  notes:
  - bad idea to tie saving to scene itself
  - better to put in a command node
  - tres file small, good
  - res even smaller

- title:    "Godot Save Game Tutorial: Save and load using Resources"
  url:      https://www.youtube.com/watch?v=ML-hiNytIqE
  status:   INC
  notes:
  - MUCH better infrastructure + example of how to save things
  - this creates a special object with Inspector interface to actually do things

- title:    How to Save a scene at run time ?
  url:      https://godotengine.org/qa/903/how-to-save-a-scene-at-run-time
  status:   done
  notes:
  - VERY GOOD, README!

- title:    What are diffrence between .scn and .tsn !? Which one is better !?
  url:      https://godotengine.org/qa/5447/what-are-diffrence-between-scn-and-tsn-which-one-is-better
  status:   done
  notes:
  - tscn versus scn
  - try scn at some point....
  - scn is COMPRESSED tscn
  - stored as BINARY, and not TEXT (t="text" in tscn)
```

## tres or tscn:
- choose tscn
- why?
- because regardless of whatever format we use, mindfulness is absolutely required
- tres simply requires the creator to explicitly state what they want saved and how they want to save/load it
- tscn however handles this automatically, and includes everything
- use of tscn requires careful thought!
- must turn everything into a prefab and store elsewhere as much as possible
- what our tscn in particular is describing is the LAYOUT and VALUES of entities
- even a TRES does the exact same thing
- but! TSCN opens natively in the editor, ready to go
- so you just need to be SMART about how you use it.
- also, maybe some function that can detect if an asset stays together/does not change would be useful
- so it can automatically export things to prefabs, and simply reference them, rather than constantly copying them
- obviously, making significant changes to a prefab can be costly
- also important to track dependencies between auto-generated prefabs....
- hnnnnggggg
- ok, maybe not worth the effort
- BUT! If we limit the users ability to significantly alter prefabs, we should be fine
- also define these prefabs sooner, and elminate any native resources to the scene

## our test case:
- just needs to know 3 things
- black ball position:  Vector3
- white ball position:  Vector3
- who's turn it is:     NodePath

# saving connections:

## scene:
- saves stuff inside itself
- save to a hash (probably just an integer)

## tree:
- builds a complete map of all connections
- must update/add/remove these
- must build ui from these
- this can be a singleton, always running in the background
- then when chrono-tree is called, we build it from this
- other advantage is its just FileRefs and NodePaths
- so small Scene to save as result
- ACTUALLY!
- we dont need NodePath!
- we just need to add things as children!
- which means the logger in each scene needs to know:
  - where to save scene (easy)
  - update the time-tree relationships (instantiate new "Save", set "File" to our save, add as child to last save)

## resources:

- (2020-11-03T15:41:00: This is where I last left off)
- (Finish Watching this (03:11): https://www.youtube.com/watch?v=AxymjihpUi4)
- (Finish Reading this: https://www.youtube.com/results?search_query=godot+singleton)

```yaml
- title:  Change scenes manually
  url:    https://docs.godotengine.org/en/stable/tutorials/misc/change_scenes_manually.html
  status: INC
  notes:

- title:  "Godot Beginner Tutorial 12: Singleton"
  url:    https://www.youtube.com/watch?v=yLbqimzD94A
  status: INC
  notes:

- title:  5 Ways to Split or Break GIF Animation Into Individual Frames
  url:    https://www.raymond.cc/blog/split-or-break-gif-animation-into-individual-frames/
  status: done
  notes:
  - check the ffmpeg instructions
  - very useful
```

# tracking change:

## two major ways of tracking changes:
- 1: Save everything each time
- 2: Save only the things that change each time

## Tracking Everything:
- Emphasis on storing references to things
- Emphasis on making save as small as possible

## Tracking Changes:
- ADD, REMOVE, CHANGE
- this requires us to do a fair bit of engineering within godot, to incrementally edit a scene
- but is far more powerful and generic then using custom full-save TRES's
- why?
- because we dont need to specify it for ecery single new feature we add
- this automatically supports whatever we add
- we also dont need to worry about the scene appearing particularly cluttered with native assets

# next big idea:

## parts:

### users:
- have a SAVES folder
- have USER folders within this folder
- each USER is a single playthrough
- each USER folder has SAVE files (0.tscn - n.tscn)
- each USER folder has one TREE file (tree.tscn)
- the TREE stores relationships between SAVEs
- this allows per-user ease of management

### ontology:
- save relation of this save with other saves in a separate file
- this is called a TREE
- why 1 file:
  - if save ontology in EACH SAVE, will require opening and loading
  - HUNDREDS of saves
  - EACH TIME the time-tree needs to be loaded
  - also makes it harder to modify the ontology if distributed across all these files

### contents:
- each SAVE is either a TRES or a TSCN
- each SAVE has 3 CATEGORIES:
    ADD:  When something new is instantiated into the scene (add this)
    DROP: When something is removed from the scene (drop this)
    SUB:  When something changes in the scene (substitute this for this)
- if TRES:
  - does not allow opening natively, will require separate saver/loader
  - still better than plain JSON (can save native stuff without much boilerplate)
- if TSCN:
  - allows opening the save file in editor natively
  - will appear as 3 NODES: [add, drop, sub]
  - each NODE will have instance of referenced SCENE-NODE with applied changes (if SUB)

### naming:
- each SAVE is given an INTEGER name
- this name is INCREMENTED per SAVE
- the last known SAVE's NAME is saved in the TREE file
- (allows ease of adding new saves, as do not need to inspect directory for highest save number)

### applying and removing changes:
- will be most sophisticated part of this
- need some mechanism that creates scenes from script
- can add/remove stuff from reading a TSCN

## implementation:

### scene saving:
- avoid singletons where possible
- instead, have chrono-logger in scene
- chrono-logger notices changes to components it is told to watch for (maybe?)
- or maybe it notices everything
- when make new save, have chrono-logger open tree.tscn and add the new save with child ref's

### ontology representation:
- if TSCN, can represent as NODEs within NODES
- where each NODE is a SAVE
- where the NAME of each NODE is an INTEGER (corresponds with name of SAVE file)
- where the CHILDREN of each NODE are the CHILDREN of each SAVE (branch)
- now, we can either store a REFERENCE to each save FILE from each NODE
- or, we can make part of the time-tree loader a file-fetcher and handler

## new names:

### not enough to have all these "trees":
- **`chrono-tree`**: the SPACE a player navigates around in
- **`tree.tscn`**:   the ONTOLOGY of saves a user makes
- **`*save.tscn`**:  the COLLECTION of saves that populate a time-tree

### from here on out, use these terms:
- chrono-space
- chrono-tree
- chrono-save

### YAML
```yaml
chrono-space:
  type:     scene
  purpose:  PLAY
  relationships:
  - LOADS: chrono-tree
  - USED-BY: player
  description:
  - the procedurally-generated user-interface to the structure of saves
  - player moves around on rails in here
  - various time-effects, gameplay happens
  elements:
    canvas: Cool background for player to move across
    player: a cursor the player moves around the canvas
    nodes:
    - each save file is drawn as one of these
    - player can "enter" or "exit" these
    paths:
    - generated and drawn between nodes
    - player moves along these
    - this is where primary gameplay in this scene resides

chrono-tree:
  type:     SCENE
  purpose:  DATA
  relationships:
  - USED-BY: chrono-space
  - TRACKS: chrono-saves
  - PLAYER: creates this through battle-gameplay
  description:
  elements:
    last-id:  INTEGER of last save game (what to use as NEXT save NAME)
    tree:     NODE-TREE of saves and their relationships

chrono-save:
  type:     SCENE
  purpose:  DATA
  relationships:
  - USED-BY: chrono-tree
  description:
  - the differences between battle-scene
  elements:
    add:  NEW items to add
    drop: OLD items to remove
    sub:  OLD items to replace, change of mesh, etc
```

# Logging:

## what:
- what if we "logged saves"?
- what would htis look like?
- what already exists?

## search terms:
- unity incremental saves
- godot logging
- godot scene logging
- unity scene logging
- godot save to stream
- unity streaming saves
- godot streaming scenes
- godot log to tscn
- godot log to tres

## questions:
- what does streaming to/from tscn/tres/json look like?
- what has been tried in the past?
- "gron", a regex-like for JSON, converts the json into this:
```py
foo = {}
foo.bar = "baz"
foo.baz = []
foo.baz[0] = 1
```

## refs:
```yaml
- title:    SirDB
  url:      https://github.com/c9fe/sirdb
  status:   INC
  comments: https://news.ycombinator.com/item?id=25004554
  notes:
  - check the HackerNews comments

- title:    Mendoza - The totally non-human readable diff format for structured JSON documents
  url:      https://www.sanity.io/blog/mendoza
  status:   INC
  comments: https://news.ycombinator.com/item?id=24943775
  notes:
  - interesting, turning JSON navigation into a state-machine

- title:    JavaScript Object Notation (JSON) Patch
  url:      https://tools.ietf.org/html/rfc6902
  status:   INC
  notes:
  - seems horribly verbose for some fairly basic operations
```

# scenes not files:

## one scene:
- we could save all saves as separate SCENES within the PLAYER save....
- so, instead of maintaining a directory of separate saves
- just put everything on the same node-tree structure
- copy the battle scene, make this the root node
- OR!

## references:
- have tree.tscn with tree.gd REFERENCE the battle scene and copy it like that!
- (makes an instance on first use of tree/first play)
- in that case...

## combine them?:
- do we want to make the chrono-space the same as the chrono-tree?
- no reason to differentiate them...?
- if we have battle (scene) as reference in tree (node)
- then we should reference time-tree (scene) from the tree (node) as well
- then we can switch between them as we please
- soo....

## separate them:
- better to have separate chrono-tree and chrono-space
- chrono-space generates a UI
- chrono-tree is the data the chrono-space uses to generate a UI

## possible concerns?:
- what is the largest tree we can have inside godot?
- what is the deepest tree we can have in godot?
- https://github.com/godotengine/godot/blob/master/scene/main/node.h
- godot uses the C++ Vector<> for children
- !cpp |
    Vector<Node *> children; // list of children
- these have a max size of<PHONE_NUMBER>213693951 elements
- but how *deep* can these go?
- how many nodes-within-nodes are we allowed to have?


text:
# Continuous

 [![Build Status](https://travis-ci.org/shafreeck/continuous.svg?branch=master)](https://travis-ci.org/shafreeck/continuous)

Continuous is a framework to upgrade a daemon binary without interrupt

# Features
* Emigrate listen fds
* Flexible controlling on multiple phases
* Graceful stop or force stop the old service
* Rollback to the old service

# Demo

[source code](./demo/main.go)

# TODO
- [ ] Add unittests

repository: distributedio/tips

gha_language: Go

repo_name: distributedio/tips


text:
# simple-spectrogram
A simple single-header spectrogram generator in C++.
The generated spectrograms use a linear scale and a hanning window function. The window size is customizable, but 256 by default.
The code is fairly simple, but not very optimal. A more optimal implementation would replace the plain O(n^2) discrete fourier transform with an FFT algorithm like Cooley-Tukey that runs in O(n log n).
This repo also contains a CMake project with a sample application that uses the header.

This project was written for educational purposes and is licensed under the MIT License.

## Example
A 300hz sine wave, on a spectrogram between 0 and 8000hz:
![300hz](images/300hz.png "300hz sine wave")

repository: Wouterdek/simple-spectrogram

repo_name: Wouterdek/simple-spectrogram


text:
# Introduction
Helperbird wordpress plugin is your all in one extension, that gives you the features to make the web more accessible and make you more productive. Providing you features like text to speech, ad removal, dyslexia support, dictation, immersive reader, overlays, reader mode, and much more.

# Contribution
## Getting Started

If you don’t have Docker and Docker Compose installed follow the steps outlined in the blog post linked above.

With Docker installed and running, in Terminal:

````
git clone https://github.com/davidyeiser/docker-wordpress-theme-setup.git
cd docker-wordpress-theme-setup
````

Then:

````
docker-compose up -d
````

Then in your browser:
````
http://localhost:8000/
````

# Questions

For questions and support please the github issues tab.

# License

[MIT](http://opensource.org/licenses/MIT)

Copyright (c) 2015-present

repository: Helperbird/wordpress-plugin

repo_name: Helperbird/wordpress-plugin


text:
# Fimaria theioleuca (Rolland) Brumm., 1962 SPECIES

#### Status
SYNONYM

#### According to
The Catalogue of Life, 3rd January 2011

#### Published in
Persoonia 2(3): 325 (1962)

#### Original name
Pseudombrophila theioleuca Rolland, 1888

### Remarks
null

repository: mdoering/backbone

path: /life/Fungi/Ascomycota/Pezizomycetes/Pezizales/Pyronemataceae/Pseudombrophila/Pseudombrophila theioleuca/ Syn. Fimaria theioleuca/README.md

repo_name: mdoering/backbone


text:
# Rogue Map Generator Version 2

---

This is the Second version of my Rogue Generator, which is written in [Typescript](http://www.typescriptlang.org/).
It uses [SystemJS](https://github.com/systemjs/systemjs) to transcribe from es6 to es5.

The algorithm used for map generation is based off of this [C# Example](http://www.roguebasin.com/index.php?title=CSharp_Example_of_a_Dungeon-Building_Algorithm)
from [roguebasin](http://www.roguebasin.com/index.php?title=Main_Page).

## Frameworks used

- [Angular 2](https://angular.io/)
- [Bootstrap 4 Alpha](http://v4-alpha.getbootstrap.com/)
- [NodeJS](https://nodejs.org/en/)
- [ExpressJS](http://expressjs.com/)


text:
# Leetcode List

- [76 - Minimum Window Substring](https://leetcode.com/problems/minimum-window-substring/)
- [96 - Unique Binary Search Trees](https://leetcode.com/problems/unique-binary-search-trees/)
- [95 - Unique Binary Search Trees II](https://leetcode.com/problems/unique-binary-search-trees-ii/)
- [442 - Find All Duplicates in an Array](https://leetcode.com/problems/find-all-duplicates-in-an-array/)
- [739 - Daily Temperatures](https://leetcode.com/problems/daily-temperatures/)
- [1004 - Max Consecutive Ones III](https://leetcode.com/problems/max-consecutive-ones-iii/)
- [239 - Sliding Window Maximum](https://leetcode.com/problems/sliding-window-maximum/)


text:
---
title: "WIP: SSH server hardening?"
date: 2020-03-30T20:25:00Z
draft: true
tags:
  - ssh
---

ssh-audit vir-d.sigma957.net
# general
(gen) banner: SSH-2.0-OpenSSH_7.6p1 Ubuntu-4ubuntu0.3
(gen) software: OpenSSH 7.6p1
(gen) compatibility: OpenSSH 7.4+, Dropbear SSH 2018.76+
(gen) compression: enabled<EMAIL_ADDRESS>
# key exchange algorithms
(kex) curve25519-sha256                     -- [info] available since OpenSSH 7.4, Dropbear SSH 2018.76
(kex<EMAIL_ADDRESS>        -- [info] available since OpenSSH 6.5, Dropbear SSH 2013.62
(kex) ecdh-sha2-nistp256                    -- [fail] using weak elliptic curves
                                            `- [info] available since OpenSSH 5.7, Dropbear SSH 2013.62
(kex) ecdh-sha2-nistp384                    -- [fail] using weak elliptic curves
                                            `- [info] available since OpenSSH 5.7, Dropbear SSH 2013.62
(kex) ecdh-sha2-nistp521                    -- [fail] using weak elliptic curves
                                            `- [info] available since OpenSSH 5.7, Dropbear SSH 2013.62
(kex) diffie-hellman-group-exchange-sha256 (2048-bit) -- [info] available since OpenSSH 4.4
(kex) diffie-hellman-group16-sha512         -- [info] available since OpenSSH 7.3, Dropbear SSH 2016.73
(kex) diffie-hellman-group18-sha512         -- [info] available since OpenSSH 7.3
(kex) diffie-hellman-group14-sha256         -- [info] available since OpenSSH 7.3, Dropbear SSH 2016.73
(kex) diffie-hellman-group14-sha1           -- [warn] using weak hashing algorithm
                                            `- [info] available since OpenSSH 3.9, Dropbear SSH 0.53

# host-key algorithms
(key) ssh-rsa (2048-bit)                    -- [fail] using weak hashing algorithm
                                            `- [info] available since OpenSSH 2.5.0, Dropbear SSH 0.28
(key) rsa-sha2-512 (2048-bit)               -- [info] available since OpenSSH 7.2
(key) rsa-sha2-256 (2048-bit)               -- [info] available since OpenSSH 7.2
(key) ecdsa-sha2-nistp256                   -- [fail] using weak elliptic curves
                                            `- [warn] using weak random number generator could reveal the key
                                            `- [info] available since OpenSSH 5.7, Dropbear SSH 2013.62
(key) ssh-ed25519                           -- [info] available since OpenSSH 6.5

# encryption algorithms (ciphers)
(enc<EMAIL_ADDRESS>       -- [info] available since OpenSSH 6.5
                                            `- [info] default cipher since OpenSSH 6.9.
(enc) aes128-ctr                            -- [info] available since OpenSSH 3.7, Dropbear SSH 0.52
(enc) aes192-ctr                            -- [info] available since OpenSSH 3.7
(enc) aes256-ctr                            -- [info] available since OpenSSH 3.7, Dropbear SSH 0.52
(enc<EMAIL_ADDRESS>              -- [info] available since OpenSSH 6.2
(enc<EMAIL_ADDRESS>              -- [info] available since OpenSSH 6.2

# message authentication code algorithms
(mac<EMAIL_ADDRESS>             -- [warn] using small 64-bit tag size
                                            `- [info] available since OpenSSH 6.2
(mac<EMAIL_ADDRESS>            -- [info] available since OpenSSH 6.2
(mac<EMAIL_ADDRESS>       -- [info] available since OpenSSH 6.2
(mac<EMAIL_ADDRESS>       -- [info] available since OpenSSH 6.2
(mac<EMAIL_ADDRESS>           -- [warn] using weak hashing algorithm
                                            `- [info] available since OpenSSH 6.2
(mac<EMAIL_ADDRESS>                 -- [warn] using encrypt-and-MAC mode
                                            `- [warn] using small 64-bit tag size
                                            `- [info] available since OpenSSH 4.7
(mac<EMAIL_ADDRESS>                -- [warn] using encrypt-and-MAC mode
                                            `- [info] available since OpenSSH 6.2
(mac) hmac-sha2-256                         -- [warn] using encrypt-and-MAC mode
                                            `- [info] available since OpenSSH 5.9, Dropbear SSH 2013.56
(mac) hmac-sha2-512                         -- [warn] using encrypt-and-MAC mode
                                            `- [info] available since OpenSSH 5.9, Dropbear SSH 2013.56
(mac) hmac-sha1                             -- [warn] using encrypt-and-MAC mode
                                            `- [warn] using weak hashing algorithm
                                            `- [info] available since OpenSSH 2.1.0, Dropbear SSH 0.28

# fingerprints
(fin) ssh-ed25519: SHA256:zijDfllcrsamBsNxKk8kbTpdt0phmK3DCH0F7cFOER4
(fin) ssh-rsa: SHA256:ZFhmjrZz5Y8qNtAzlDaPMdRe8QQr6VkAPmI63G3icww

# algorithm recommendations (for OpenSSH 7.6)
(rec) -ecdh-sha2-nistp256                   -- kex algorithm to remove
(rec) -ecdh-sha2-nistp384                   -- kex algorithm to remove
(rec) -ecdh-sha2-nistp521                   -- kex algorithm to remove
(rec) -ecdsa-sha2-nistp256                  -- key algorithm to remove
(rec) -ssh-rsa                              -- key algorithm to remove
(rec) -diffie-hellman-group14-sha1          -- kex algorithm to remove
(rec) -hmac-sha1                            -- mac algorithm to remove
(rec<EMAIL_ADDRESS>          -- mac algorithm to remove
(rec) -hmac-sha2-256                        -- mac algorithm to remove
(rec) -hmac-sha2-512                        -- mac algorithm to remove
(rec<EMAIL_ADDRESS>               -- mac algorithm to remove
(rec<EMAIL_ADDRESS>            -- mac algorithm to remove
(rec<EMAIL_ADDRESS>                -- mac algorithm to remove

# additional info
(nfo) For hardening guides on common OSes, please see: <https://www.ssh-audit.com/hardening_guides.html>

---


text:
# @wasm-tool/rust-loader

> Webpack plugin for Rust

## Installation

```sh
yarn add --dev @wasm-tool/rust-loader
```

## Usage

It is *highly* recommended to use the [Rust Webpack Template](https://github.com/rustwasm/rust-webpack-template) to create a new Rust project.

----

But if you instead want to manually create the project yourself, follow these steps:

Create a `Cargo.toml` file which has the `cdylib` crate type:

```toml
[package]
name = "foo"
version = "0.1.0"
edition = "2018"

[lib]
crate-type = ["cdylib"]

[dependencies]
wasm-bindgen = "0.2.48"

[dependencies.web-sys]
version = "0.3.25"
features = ["console"]
```

And create a `src/lib.rs` file:

```rust
use wasm_bindgen::prelude::*;
use web_sys::console;

#[wasm_bindgen(start)]
pub fn main_js() {
    console::log_1(&JsValue::from("Hello world!"));
}
```

Now add the loader to your `webpack.config.js` and import the `Cargo.toml` file:

```js
module.exports = {
  entry: {
    index: "./Cargo.toml"
  },
  module: {
    rules: [{ test: /Cargo\.toml$/, use: "@wasm-tool/rust-loader" }]
  }
};
```

Then just run `webpack` as usual.

It also fully supports `webpack-dev-server` (including live reloading):

```js
module.exports = {
  entry: {
    index: "./Cargo.toml"
  },
  devServer: {
    liveReload: true,
    open: true,
    noInfo: true,
    overlay: true
  },
  module: {
    rules: [{ test: /Cargo\.toml$/, use: "@wasm-tool/rust-loader" }]
  }
};
```

repository: wasm-tool/rust-loader

repo_name: wasm-tool/rust-loader


text:
# Employee Manager System
  [![GitHub followers](https://img.shields.io/github/followers/wilsoncollin7.svg?style=social&label=Follow&maxAge=2592000)](https://github.com/wilsoncollin7?tab=followers) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

  This project allows a manager to manage their employees! The user can cycle through several differnt options to view differnt sets of data, add data, update data, and delete data! This program is made using Node.js and MySQL.

  ## Table of Contents

  - [Installation](#installation)
  - [Usage](#usage)
  - [License](#license)
  - [Contributing](#contributing)
  - [Tests](#tests)
  - [Questions](#questions)

  ## Installation

  Run node index.js to start to program, the mySQL data base must be set up first on your local server.

  ## Usage

  This program uses Inquirer to ask the user different question. The user can:

  - view all employees
  - view all departmenst
  - view all roles
  - add an employee
  - add a department
  - add a role
  - update an employee role
  - delete an employee!

  The data base is set up in MySQL and the schema and seed files are provided in the db folder.

  ## License

  This aplication is made with the [MIT License](https://opensource.org/licenses/MIT)

  ## Contributing

  To contribute please contact me!

  ## Tests

  If you find any problems or errors please contact me!

  ## Questions

  For any questions you might have, you can email me at<EMAIL_ADDRESS>You can also check out my [GitHub Profile](https://github.com/wilsoncollin7).


text:
# Vaporwave Endurance

Vaporwave Endurance is a tower defense game but reinterpreted in a first person perspective with a vaporwave touch. The game is based on rounds and each round will be harder.
The game was developed for the course of Interactive Graphics at Sapienza University of Rome.

## Summary
- [Getting Started](#getting_started)
- [Built with](#built-with)
- [Authors](#authors)
- [License](#license)
- [Acknowledgments](#acknowledgments)

## Getting Started

Just download the project and open `index.html` file, hit the play button and have fun!
If you want, you can try [the live demo](https://fabiodis.github.io/finalproject-vaporwaveendurance/).
To learn more about the project, you can read the [documentation](documentation.pdf).

## Built With

* [ThreeJS](https://threejs.org/)

## Authors

* **Fabio Di Spazio** - [FabioDiS](https://github.com/FabioDiS)
* **Giovanbattista Abbate** - [giabb](https://github.com/giabb)

## License

This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details

## Acknowledgments

- Billie Thompson - Provided README Template - [PurpleBooth](https://github.com/PurpleBooth)

repository: giabb/finalproject-vaporwaveendurance

repo_name: giabb/finalproject-vaporwaveendurance


text:
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

**Questions**

- Is this a bug concerning building of ink! smart contracts?
    - If **yes** then you might instead want to file a bug report to ink!'s build tool: https://github.com/paritytech/cargo-contract
- Is this a bug that appears when interacting with smart contracts via the Polkadot JS browser UI?
    - If **yes** then you might instead want to file a bug report to the Polkadot JS Apps project instead: https://github.com/polkadot-js/apps

**FAQ**

- Are you using the nightly Rust channel to compile your smart contract?
- Are you using an up-to-date `cargo-contract`? Check via `cargo contract --version`.
    - If you are unsure please tell us your version noted there.
- Are you using an up-to-date ink! version in your smart contract?
    - You can check this by looking into the `[dependencies]` section of your `Cargo.toml`.
    - If you are unsure please tell us your version noted there.

**Describe the bug**
A clear and concise description of what the bug or odd behavior is.

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Additional context**
Add any other context about the problem here.

repository: paritytech/ink

gha_language: Rust

repo_name: paritytech/ink


text:
# log FPGA resource usage to CSV file

store and plot LUT, flip-flop and max frequency stats.

## setup

install requirements.txt:

    pip3 install -f requirements.txt

## usage

add as a git hook:

1. add -l switches to log output to files for yosys and nextpnr in your Makefile
1. add a [post-commit](post-commit) hook to your git repo like this:
    1. vi post-commit # edit the hook to fit your repo
    1. cp post-commit .git/hooks/post-commit
1. now everytime you commit, the resource usage will be added to the log file

or in your makefile:

    logluts:
        $(LOG_LUTS) --add-commit --git ../

    plotluts:
        $(LOG_LUTS) --plot --git ../

## plotting

an interactive plot is available with the --plot argument.
Move the mouse to see the commit hash and message

![luts](luts.png)

repository: splinedrive/logLUTs

repo_name: splinedrive/logLUTs


text:
# ShutDownCellTimerLib

[![CI Status](https://img.shields.io/travis/wangbo1185742894/ShutDownCellTimerLib.svg?style=flat)](https://travis-ci.org/wangbo1185742894/ShutDownCellTimerLib)
[![Version](https://img.shields.io/cocoapods/v/ShutDownCellTimerLib.svg?style=flat)](https://cocoapods.org/pods/ShutDownCellTimerLib)
[![License](https://img.shields.io/cocoapods/l/ShutDownCellTimerLib.svg?style=flat)](https://cocoapods.org/pods/ShutDownCellTimerLib)
[![Platform](https://img.shields.io/cocoapods/p/ShutDownCellTimerLib.svg?style=flat)](https://cocoapods.org/pods/ShutDownCellTimerLib)

## Example

To run the example project, clone the repo, and run `pod install` from the Example directory first.

## Requirements

## Installation

ShutDownCellTimerLib is available through [CocoaPods](https://cocoapods.org). To install
it, simply add the following line to your Podfile:

```ruby
pod 'ShutDownCellTimerLib'
```

## Author

wangbo1185742894<EMAIL_ADDRESS>
## License

ShutDownCellTimerLib is available under the MIT license. See the LICENSE file for more info.


text:
# Encryption Tools #

Collection of encryption tools from [pyca/cryptography](https://cryptography.io/en/latest/) served through a flask application.

## features ##

- Password Generator
- [Password Based Key Generator](https://cryptography.io/en/latest/hazmat/primitives/key-derivation-functions/#variable-cost-algorithms)
- [Symmetric Encryption/Decryption](https://cryptography.io/en/latest/fernet/)
- [RSA Encryption/Decryption](https://cryptography.io/en/latest/hazmat/primitives/asymmetric/rsa/)
- user authentication
- profile page for viewing/downloading keys and encrypted files
- sqlite3 database for storage

## Installing ##

    $ python3 -m venv env
    $ source env/bin/activate
    $ pip install -r requirements.txt

## Running locally ##

    FLASK_DEBUG=TRUE FLASK_APP=encryption_tools flask run

## Running tests ##

    python setup.py test

## sources ##

- [CSS by bootstrap](https://getbootstrap.com/docs/5.0/getting-started/introduction/)
- [bootstrap theme](https://github.com/ThemesGuide/bootstrap-themes/tree/master/fresca)
- [pyca/cryptography](https://cryptography.io/en/latest/)