text:
# kubectl krew template repo

There's a lot of scaffolding needed to set up a good kubectl plugin. This repo is a GitHub Template Repo to make it easy to set all of this scaffolding up for a new repo.

The assumptions made are:
1. You'll write your plugin in go
2. You want client-go to interact with the cluster
3. You want all of the kubectl flags available to your plugin
4. Your plugin's home will be a github.com repo
5. Your plugin will work in Linux, MacOS and Windows

## Create your repo

[Start here](https://github.com/replicatedhq/krew-plugin-template/generate) to create a new repo based on this template. This is not a fork, it will make a copy of this repo into your own organization or GitHub account.

Click that, and create your own version of this repo. Clone it locally. The rest of the steps you will be performing on your local copy.

## Make it yours

Once you have your own repo created locally, change to the directory and run:

```shell
make setup
```

This will prompt you for a few things, such as your GitHub org, repo name and plugin name. The setup application will then update the import paths and code with the data you provided.

(Note, once you've run this step, these instructions will no longer be present in your repo. You can always vew then at [https://github.com/replicatedhq/krew-plugin-template](https://github.com/replicatedhq/krew-plugin-template)).

Commit and check it in to your repo!

```shell
git add .
git commit -m "Updating from template"
git push -u origin master
```

## Write your Plugin

Next, open the pkg/plugin/plugin.go file. This is where you can start writing your plugin.

For an example, take a look at the [outdated](https://github.com/replicatedhq/outdated) plugin that inspired this template.

To make a local build:

```shell
make bin
```

## Creating a release

To create a new release of your plugin, create and push a tag.

```shell
git tag v0.1.0 -m 'initial release'
git push --tags
```

This repo has a built-in GitHub Action that will handle the build process. We use [GoReleaser](https://goreleaser.com) to create tagged releases. This will create all three binaries and push them to the releases page when you push a tag. It will take a few minutes to complete, so be patient.

## Submitting to Krew

Be sure to read the guidelines on the Krew Developer guide before submitting you plugin. This is not automated (yet). We've created a starting point for your plugin manifest, look for it in deploy/krew/plugin.yaml.

## Share!

Finally, we'd love to hear if you've used this template. Let us know on Twitter at @replicatedhq. We've written a few kubectl plugins too, and are always curious to see what other people are working on.

repository: yashbhutwala/krew-plugin-template

repo_name: yashbhutwala/krew-plugin-template


text:
Bans/block lists a hash in CBEP/Bit9.
## Script Data
---

| **Name** | **Description** |
| --- | --- |
| Script Type | python |
| Tags | carbon-black-protection, bit9 |

## Dependencies
---
This script uses the following commands and scripts.
* cbp-fileRule-update

## Inputs
---

| **Argument Name** | **Description** |
| --- | --- |
| hash | The hash value(s) to ban (comma-separated). |

## Outputs
---
There are no outputs for this script.

license: MIT

repository: demisto/content

branch_name: refs/heads/master

extension: md

gha_language: Python

gha_license_id: MIT

license_type: permissive

repo_name: demisto/content


text:
---
id: rating
title: Rating
---

import useBaseUrl from '@docusaurus/useBaseUrl';
import Props from './props/rating.md'

Ratings are used to collect measurable feedback from users. Use Rating over an
Input where imagery can increase user interaction.

> This component is imported from [react-native-ratings](https://github.com/Monte9/react-native-ratings)

## Usage

```js
import { Rating, AirbnbRating } from 'react-native-elements';

ratingCompleted(rating) {
  console.log("Rating is: " + rating)
}

<AirbnbRating />

<AirbnbRating
  count={11}
  reviews={["Terrible", "Bad", "Meh", "OK", "Good", "Hmm...", "Very Good", "Wow", "Amazing", "Unbelievable", "Jesus"]}
  defaultRating={11}
  size={20}
/>

<Rating
  showRating
  onFinishRating={this.ratingCompleted}
  style={{ paddingVertical: 10 }}
/>

<Rating
  type='heart'
  ratingCount={3}
  imageSize={60}
  showRating
  onFinishRating={this.ratingCompleted}
/>

const WATER_IMAGE = require('./water.png')

<Rating
  type='custom'
  ratingImage={WATER_IMAGE}
  ratingColor='#3498db'
  ratingBackgroundColor='#c8c7c8'
  ratingCount={10}
  imageSize={30}
  onFinishRating={this.ratingCompleted}
  style={{ paddingVertical: 10 }}
/>
```

### Read-only mode

```js
const { rating } = this.props;

<Rating imageSize={20} readonly startingValue={rating} style={styles.rating} />;
```

### Fractions

```html
<Rating showRating fractions="{1}" startingValue="{3.3}" />
```

![Fractions demo gif](https://cloud.githubusercontent.com/assets/241553/26780040/e8cd1a2c-49f8-11e7-8859-6dd9b4e0a779.gif)

---

<Props />

---

branch_name: refs/heads/next

gha_language: MDX


text:
# grunt-tex-wordcount [![Build Status](https://travis-ci.org/grunt-tex/grunt-tex-wordcount.svg?branch=master)](https://travis-ci.org/grunt-tex/grunt-tex-wordcount)

Part of the [grunt-tex](https://github.com/grunt-tex) suite of LaTeX-orientated Grunt tasks.

This plugin can be used to calculate the word count of a LaTeX document and all it's inclusions using the applications `detex` and `wc`.

## Getting Started
This plugin requires Grunt `~0.4.5` and `detex` + `wc` to be available.

If you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:

```shell
npm install grunt-tex-wordcount --save-dev
```

Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:

```js
grunt.loadNpmTasks('grunt-tex-wordcount');
```

## The "wordcount" task

### Overview
In your project's Gruntfile, add a section named `wordcount` to the data object passed into `grunt.initConfig()`.

```js
grunt.initConfig({
  wordcount: {
    your_target: {
      // Target-specific file lists and/or options go here.
    }
  }
});
```

### Options

There are no options available for this task.

### Usage Examples

#### Basic
This is the most basic usage of wordcount:

```js
grunt.initConfig({
  wordcount: "document.tex"
});
```

#### Multitask
In this example, wordcount is used as a multitask with different notation for each document.

```js
grunt.initConfig({
  wordcount: {
    documentone: {
      files: [
        { src: "documentone.tex" }
      ]
    },
    documenttwo: "documenttwo.tex"
  }
});
```

## 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](http://gruntjs.com/).

## Release History

* 2015-01-08   v0.1.0   Initial release

repository: gruntjs-updater/grunt-tex-wordcount

repo_name: gruntjs-updater/grunt-tex-wordcount


text:
# S3_extract
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)

Current S3Snow processor version: 2.3

The repository contains 3 tools:

- *s3_extract_snow_products*: the script is designed to extract the outputs from the S3 OLCI SNOW processor based on a list of Sentinel-3 (Hereafter “S3”) OLCI imagery, for a named list of user-defined lat/lon coordinates.
- *s3_band_extract*: the script allows to extract values from S3 bands (OLCI or SLSTR) from a list of S3 images for a named list of user-defined lat/lon coordinates.
- *list_sat_bands*: returns a list of all available bands from an S3 OLCI or SLSTR scene.

The work requires **SNAP 7** and the following experimental SNAP plugins:

 - s3tbx-snow-2.3-SNAPSHOT
 - s3tbx-olci-o2corr-0.81-SNAPSHOT
 - s3tbx-idepix-olci-s3snow-0.82-SNAPSHOT
 - snap-slope-0.92-SNAPSHOT (if the S3 SNOW DEM products are to extracted)

Code developed within the **Sentinel-3 for Science, Land Study 1: Snow**   project led by Jason Box. More information at [snow.geus.dk](http://snow.geus.dk/).

Development and testing: Maxim Lamare, Jason Box, and Jonas Kvist Andersen.

# Content

1. [Introduction](#intro)
2. [Requirements and setup](#setup)
3. [Workflow](#workflow)

# Introduction
The s3_extract_snow_products script, developed by the [S34Sci Land Study 1: Snow](http://snow.geus.dk/), extracts the outputs of the S3Snow algorithm results for a list of S3 OLCI L1C scenes for a user-supplied list of latitude and longitude coordinates.

# Requirements and setup
The processing of the S3 images is performed with [snappy](https://senbox.atlassian.net/wiki/spaces/SNAP/pages/19300362/How+to+use+the+SNAP+API+from+Python): the SNAP Java API from Python. The installation of the libraries is detailed below.
The use of Anaconda is strongly recommended to run the scripts provided in this repository, and the installation steps provided assume the use of a Conda environment.

Note: there are 2 branches on this repository:
1. the master branch, designed for Mac OS
2. a Linux branch

There is currently no Windows OS support.

_Setup steps:_

1. You can get Anaconda or Miniconda [here](https://www.anaconda.com/download)
2. The current version of the script was designed to work with Python 3.4 or 3.5.
3. Install SNAP 7 and the S3Snow plugins (listed below). The S34Sci Snow [SUM](https://s3tbx-snow.readthedocs.io/en/latest/) describes the plugins.
4. Install or verify that JDK is installed on your system and JDK_HOME path is set.
5. Create a Conda environment (see steps below) and  configure snappy to work with the environment's Python interpreter (the hardest part). The instructions are found [here](https://senbox.atlassian.net/wiki/spaces/SNAP/pages/50855941/Configure+Python+to+use+the+SNAP-Python+snappy+interface).

For MacOS users @mankoff created an installation guide (essentially the same for Linux or Windows systems):

    # create conda environement
    conda create -n SNAP python=3.4
    source activate SNAP

    # install pandas
    conda install pandas

    # install jpy
    cd /local/folder/of/your/choice
    git clone https://github.com/bcdev/jpy.git
    cd jpy/
    python setup.py bdist_wheel
    cp dist/*.whl ~/.snap/snap-python/snappy

    # set up snappy
    # NOTE: customize paths here to where SNAP and Anaconda are
      installed
    ~/Applications/snap/bin/snappy-conf ~/local/anaconda/envs/SNAP/bin/python

    cd ~/.snap/snap-python/snappy
    python setup.py install

    # test
    python
    import snappy # no error message = works.

Note: for advanced users, the Conda environment file is provided in the repository > *req.txt*

# Example workflow

## s3_extract_snow_products.py

Run  `python s3_extract_snow_products.py -h` for help.

The scripts needs the following obligatory inputs:

 - ***-i, --input***: the path to the folder containing unzipped S3 OLCI L1C granules (scenes). Each unzipped folder (.SEN3) contains the NetCDF data files (.nc) and an XML file (.xml). The script will also access S3 scenes that are located in sub-directories in the input path.
 - ***-c, --coords***: the path to a file containing the coordinates of the pixels values to extract from the S3 images. The file should be in a .csv format with each row containing: *Name, lat, lon*, with the latitude and longitude in degrees (EPSG:4326). I.E; Inukjuak, 58.4550, -78.1037
 - **-o, --output:** the path to the output folder, where a .csv file for each site will be created, containing the output values from the S3Snow processor. A list of the S3 scenes for which the algorithm failed is created in a separate file. See note below.

The following optional inputs can be specified:

- ***-p, --pollution***: activate the snow pollution option in the S3Snow processor. To run the processor for polluted snow: `"yes", "true", "t", "y", or "1"`. To run the processor for clean snow: `"no", "false", "f", "n", or "0"`. By default, the snow pollution flag is deactivated.

 - ***-d, --delta_p***: set the trigger to activate snow polluted mode. If the pollution flag is activated, and if the difference between the measured reflectance and the theoretical reflectance for clean snow is lower than the specified *delta_p* value, the polluted snow algorithm is activated. If the difference is smaller than the *delta_p*, the snow is considered clean and the polluted snow algorithm is not activated. Has no effect if the pollution flag is turned off.

 - **-g, --gains:** multiply the Bottom-of-Atmosphere reflectance by the gains specified by the [Ocean Color SVC](https://www.eumetsat.int/website/wcm/idc/idcplg?IdcService=GET_FILE&dDocName=PDF_S3A_PN_OLCI_L2&RevisionSelectionMethod=LatestReleased&Rendition=Web) before calculating albedo. Expert option only: it is not recommended to activate this option. To activate the use of the gains: `"yes", "true", "t", "y", or "1"`. To deactivate the use of the gains: `"no", "false", "f", "n", or "0"`. By default, the gains flag is deactivated.

 - **-e, --elevation:** run the S3Snow slope processor that calculates the elevation, slope, aspect, and subpixel variance from the DEM. The algorithm currently uses the default DEM band that is provided within the S3 OLCI product. To run the slope processor use: `"yes", "true", "t", "y", or "1"`. To run the algorithm without the aforementioned variables in the output specify the options: `"no", "false", "f", "n", or "0"`. By default, the option is turned off.

 - **-r, --recovery:** run the algorithm in recovery mode. If the processing stopped in the middle of a run for some reason, the output temporary files are not sorted. The recovery mode will attempt to convert the temporary files to final files, therefore reducing the number of images to re-process the next time. A manual selection of the unprocessed scenes in the input folder will be necessary to run only the unprocessed scenes after recovery mode (don't forget to save the recovery mode output files elsewhere or they will be overwritten). In recovery mode, the **elevation** flag has to be set to the value of the failed run otherwise the code will crash. Activate recovery mode by setting the flag to `"yes", "true", "t", "y", or "1"`. To run in normal mode: `"no", "false", "f", "n", or "0"`. By default, the option is turned off.

- **-f, --platform** specify the Sentinel-3 platform (i.e. Sentinel-3A, -3B, or both) to include data from. Options are 'A', 'B', or 'AB' (for both platforms).

**Example run:**

    python s3_extract_snow_products.py -i "/path/to/folder/containing/S3/folders"\
    -c "/path/to/input/csvfile.csv" -o "/path/to/output/folder" -p false -d 0.05 -g false

**Outputs:**
The output csv file contains:

- Year, Month, Day, Hour, Minute, Second of acquisition
- Day of year of acquisition
- Satellite platform ID (S3A = 0, S3B = 0)
- Grain Diameter (mm), SSA (m2.kg-1)
- NDSI, NDBI
- Cloud flag (cloud = 1, no cloud = 0)
- Solar and viewing angles
- Planar and spherical albedo (Shortwave, Visible, NIR)
- TOA reflectance for the 21 bands (Oa_reflectance)
- BOA reflectance for the 21 bands (rBRR)
- Spectral planar albedo for the 21 bands

## s3_band_extract.py

Run  `python s3_band_extract.py -h` for help.

The scripts needs the following obligatory inputs:

 - ***-i, --insat***: the path to the folder containing unzipped S3 OLCI L1C granules (scenes). Each unzipped folder (.SEN3) contains the NetCDF data files (.nc) and an XML file (.xml).
 - ***-c, --coords***: the path to a file containing the coordinates of the pixels values to extract from the S3 images. The file should be in a .csv format with each row containing: *Name, lat, lon*, with the latitude and longitude in degrees (EPSG:4326). i.e; Inukjuak, 58.4550, -78.1037
 - **-o, --output:** the path to the output folder, where a .csv file for each site will be created, containing the output values from the S3Snow processor. A list of the S3 scenes for which the algorithm failed is created in a separate file. See note below.
 - **-b, --bands:** a list of band names for which the data extraction will occur. The bands can be regular bands, TiePointGrids, or Masks. The band names should be listed, separated by a space. For example to extract data from S3 OLCI first two radiance bands: `Oa01_radiance Oa02_radiance`.

The following optional inputs can be specified:

- ***-r, --res***: specifies the reader to be used to open SLSTR images. By default the 500m resolution reader is specified, but the 1km reader can be set using this flag. The flag values can either be `"500"` or `"1000"`. For specific applications only.
- **-p, --platform** specify the Sentinel-3 platform (i.e. Sentinel-3A, -3B, or both) to include data from. Options are 'A', 'B', or 'AB' (for both platforms).

**Example run:**

    python s3_band_extract.py -i "/path/to/folder/containing/S3/folders"\
    -c "/path/to/input/csvfile.csv" -o "/path/to/output/folder" -b Oa01_radiance quality_flags_bright SZA

**Outputs:**
The output csv file contains:

- Year, Month, Day, Hour, Minute, Second of acquisition
- Day of year of acquisition
- Satellite platform ID (S3A = 0, S3B = 1)
- The values for all the bands specified as inputs

## list_sat_bands.py

Run `python list_sat_bands.py -h` for help.

The script takes only two inputs:

- ***-i, --insat***: the path to a single S3 OLCI or SLSTR scene, i.e. a .SEN3 folder containing NetCDF data files (.nc) and an XML file (.xml).
- ***-f, --file***: path to the output text file to which the list of bands will be written.

**Example run:**

    python list_sat_bands.py -i "/path/to/folder/containing/S3/scene"\
    -f "/path/to/output/textfile.txt"

**Outputs:**
The output text file contains:

- The OLCI/SLSTR band names
- The OLCI/SLSTR TiePointGrid names
- The OLCI/SLSTR mask names


text:
# Glossary

**New** - Any item created after the creation of the back-up.

# Questions

## What *new* items will be lost after a database restore?

The following **new** items will be lost: -

- changes / reviews
- groups
- dashboards

## What happens to *new* reviews after a restore?

**New** review are lost if the database is restored as they are stored in the database after it was backed up.

## What happen to *new* repos after a restore?

**New** repos are picked-up by the reindexing of gerrit. However if the database is restored their reviews will be lost.

## Is it possible to restore deleted repos?

> **TODO:** Add support for repo only restore, via ```gerrit_backup_tool```.

Yes, via restore argument ```--repo-list gerrit_backup_repos.txt```. However currently this will restore the database also, deleting **new** reviews. So it's a good idea to do a back-up first and then a restore.

## Have to select a specific back-up versions

> **TODO:** Implement, the main task was to restore data onto a new server after an unrecovable failer of an active server.


text:
# eslint-plugin-skeleton

## Note

I will update this module only on request. If you want an update, create a pull request or raise an issue.

## Description

ESLint Plugin with recommended rules and mixins for the different environments of an Angular web application.

## Integration

Either insert it as a local folder with a relative path in the `package.json` (see [akSkeleton](https://github.com/akullpp/akSkeleton)) or use it as node module.

Your root `.eslintrc` needs to look the following:

```json
{
  "extends": "./node_modules/eslint-plugin-skeleton/config/eslintrc.base"
}
```

The `.eslintrc` located in your source files (e.g. `src/`) should extend the browser mixin:

```json
{
  "extends": "../node_modules/eslint-plugin-skeleton/config/mixins/browser"
}
```

The `.eslintrc` located in your test files (e.g. `test/`) should extend the test mixin:

```json
{
  "extends": "../node_modules/eslint-plugin-skeleton/config/mixins/test"
}
```

## Configuration & Mixins

1. The `eslintrc.base` contains all the defaults and main rules. It ensures that the root files are linted as a node environment.
2. The `browser` mixin sets up the rules and environment for linting client-side scripts.
3. The `test` mixin is exclusively used for the test environment.

repository: akullpp/eslint-plugin-skeleton

repo_name: akullpp/eslint-plugin-skeleton


text:
# Blog BE Next

The backend platform for Yancey Official Blog with Node.js, NestJS, MongoDB, GraphQL, JWT and more...

_This library is part of the [BEG (Blog Environment Group)](https://github.com/Yancey-Blog)_ ecosystem 📖

![Build Status](https://github.com/Yancey-Blog/blog-be-next/actions/workflows/github-actions.yml/badge.svg)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/899c1498056d402284353047fcde0632)](https://www.codacy.com/manual/YanceyOfficial/blog-be-next?utm_source=github.com&utm_medium=referral&utm_content=Yancey-Blog/blog-be-next&utm_campaign=Badge_Grade)
[![codecov](https://codecov.io/gh/Yancey-Blog/blog-be-next/branch/master/graph/badge.svg)](https://codecov.io/gh/Yancey-Blog/blog-be-next)
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2FYancey-Blog%2Fblog-be-next.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2FYancey-Blog%2Fblog-be-next?ref=badge_shield)

[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)
![Code Style](https://camo.githubusercontent.com/c83b8df34339bd302b7fd3fbb631f99ba25f87f8/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f64655f7374796c652d70726574746965722d6666363962342e737667)
[![Version](https://img.shields.io/github/package-json/v/Yancey-Blog/blog-be-next)](https://github.com/Yancey-Blog/blog-be-next)
[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-green.svg)](https://github.com/Yancey-Blog/blog-be-next/pulls)
[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)

[![Gitter](https://badges.gitter.im/yancey-official/community.svg)](https://gitter.im/yancey-official/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
[![Average time to resolve an issue](http://isitmaintained.com/badge/resolution/Yancey-Blog/blog-be-next.svg)](http://isitmaintained.com/project/Yancey-Blog/blog-be-next 'Average time to resolve an issue')
[![Percentage of issues still open](http://isitmaintained.com/badge/open/Yancey-Blog/blog-be-next.svg)](http://isitmaintained.com/project/Yancey-Blog/blog-be-next 'Percentage of issues still open')

⭐ _Found it cool? Want more updates?_ [**Show your support by giving a ⭐**](https://github.com/Yancey-Blog/blog-be-next/stargazers)

---

## Menu

- [Blog BE Next](#blog-be-next)
  - [Menu](#menu)
  - [Available Scripts](#available-scripts)
    - [yarn build](#yarn-build)
    - [yarn watch](#yarn-watch)
    - [yarn document](#yarn-document)
    - [yarn test](#yarn-test)
    - [yarn commit](#yarn-commit)
  - [Contributing](#contributing)
    - [Code of Conduct](#code-of-conduct)
    - [Contributing Guide](#contributing-guide)
    - [Good Issues](#good-issues)
    - [Commitizen](#commitizen)
    - [Env Files](#env-files)
    - [E2E Testing](#e2e-testing)
  - [Changelogs](#changelogs)
  - [TODOs](#todos)
  - [License](#license)

## Available Scripts

In the project directory, you can run:

### yarn build

Builds the app for production to the `dist` folder.
This script will delete the old `dist` folder before build.

### yarn watch

Runs the app in the development mode.
Open [http://localhost:3002](http://localhost:3002) to view it in the browser. The page will reload if you make edits. You will also see any lint errors in the console.

### yarn document

Via [compodoc](https://github.com/compodoc/compodoc) to generate an awesome document for this app.

### yarn test

Runs Jest via yarn test.

### yarn commit

An optional way to use `git cz` if you don't want to install `commitizen` globally.

[⇧ back to top](#Menu)

## Contributing

The main purpose of this repository is to continue to evolve BEG (Blog Environment Group), making it faster and easier to use. Development of Blog BE Next happens in the open on GitHub, and we are grateful to the community for contributing bugfixes and improvements. Read below to learn how you can take part in improving Blog BE Next.

### [Code of Conduct](./CODE_OF_CONDUCT.md)

[BEG](https://github.com/Yancey-Blog) has adopted a Code of Conduct that we expect project participants to adhere to. Please read [the full text](./CODE_OF_CONDUCT.md) so that you can understand what actions will and will not be tolerated.

### [Contributing Guide](./CONTRIBUTING.md)

Read our [contributing guide](./CONTRIBUTING.md) to learn about our development process, how to propose bugfixes and improvements, and how to build and test your changes to Blog BE Next.

### Good Issues

Please make sure to read the [Issue Reporting Checklist](./.github/ISSUE_TEMPLATE/bug_report.md) before opening an issue. Issues not conforming to the guidelines may be closed immediately.

### Commitizen

This app follows the [Angular Team's Commit Message Guidelines](https://github.com/angular/angular/blob/master/CONTRIBUTING.md#commit), your commit will be checked by commitlint, please use `git cz` instead of `git commit`. For this reason, you should install `commitizen` globally or use `yarn commit` instead.

### Env Files

Creating `production.env`, `development.env` and `test.env` to save specified environment variables. Common parameters cound be filled in `.env`. Both `DATABASE_USER` and `DATABASE_PWD` are optional parameters in `development.env` and `test.env` file. Furthermore, `NEED_SIMULATE_NETWORK_THROTTLE` is only working on the development environment.

```bash
NODE_ENV=<YOUR_NODE_ENV>
APP_PORT=<YOUR_APP_PORT>
DATABASE_HOST=<YOUR_DATABASE_HOST>
DATABASE_PORT=<YOUR_DATABASE_PORT>
DATABASE_COLLECTION=<YOUR_DATABASE_COLLECTION>
# `DATABASE_USER` and `DATABASE_PWD` are optional parameters in
# `development.env` and `test.env` file
DATABASE_USER=<YOUR_DATABASE_USER>
DATABASE_PWD=<YOUR_DATABASE_PWD>
BANDWAGON_SECRET_KEY=<YOUR_BANDWAGON_SECRET_KEY>
BANDWAGON_SERVER_ID=<YOUR_BANDWAGON_SERVER_ID>
IP_STACK_ACCESS_KEY=<YOUR_IP_STACK_ACCESS_KEY>
GOOGLE_RECAPTCHA_KEY=<YOUR_GOOGLE_RECAPTCHA_KEY>
JWT_SECRET_KEY=<YOUR_JWT_SECRET_KEY>
JWT_EXPIRES_TIME=<YOUR_JWT_EXPIRES_TIME>
# Only works on the development environment.
NEED_SIMULATE_NETWORK_THROTTLE=<BOOLEAN>
```

### E2E Testing

We use e2e testing for every module and test them at CI stage, you must write related test cases before PR.

[⇧ back to top](#Menu)

## Changelogs

The following are **prehistoric changelogs** on building infrastructure for this app. Just as a memorial. See the real detailed changes for each release are documented in the [CHANGELOG](./CHANGELOG.md).

- 2019-12-03 Integrates e2e testing.

- 2019-11-26 Integrates JWT.

- 2019-11-07 Integrates dotenv.

- 2019-11-04 Integrates GraphQL.

- 2019-10-20 Integrates MongoDB and write the first RESTful CRUD.

- 2019-10-12 Initital repo.

[⇧ back to top](#Menu)

## TODOs

- ~~[ ] Full text search for post (We are using Algolia Search)~~

- [ ] Fine-grained type verification system optimization

- [ ] Supports forget password

- [ ] Supports role-based permission system

- [ ] Supports two factor authentication (Both of TOTP and SMS)

- [ ] Dockerize

[⇧ back to top](#Menu)

## License

Blog BE Next is under the [MIT licensed](https://opensource.org/licenses/MIT). See the [LICENSE](./LICENSE) file for the full license text.

repository: Yancey-Blog/blog-be-next

gha_language: TypeScript

repo_name: Yancey-Blog/blog-be-next


text:
## Aragon Community Meeting 10 Write-Up for March 2018

### Jorge – Tech lead

#### Finally launched Aragon v0.5! 🚀🦅

- Release notes: [https://github.com/aragon/aragon/releases/tag/0.5.0](https://github.com/aragon/aragon/releases/tag/0.5.0)

- So proud the work the entire team has done to get us here 💞

- Launch was flawless from the communications and community side and technically
no big issues have been raised. So congrats everyone on an amazingly uneventful
launch!

#### Helped onboard [Chris Remus](https://blog.aragon.one/team-interviews-chris-aragons-product-manager-c243c716213), Aragon's product manager

- Chris joined us in Madrid the first week of March, for a productive week of
organizing the product pipeline and assess our current processes.

- Chris already helped a lot coordinating and organizing the last mile of the v0.5 launch,
and he will be the owner of the next development cycles.

#### Tech

- [New Vault](https://github.com/aragon/aragon-apps/pull/129) with support for
arbitrary token standards was developed and integrated as part of the release.
With this new Vault, Aragon organizations are able to own ERC777 and ERC721 NFTs
in an easy way.

- We deployed the first instance of [apm-serve](https://github.com/aragon/apm-serve)
a bridge to APM in the web2 at [aragonpm.com](http://aragon.aragonpm.com)

- Worked on the server infrastructure to support Aragon v0.5. Even though it is
fully decentralized and trustless thanks to IPFS and the APM, having some support
nodes is helpful. Anyway all state is computed trustlessly on every client, no
node-mongo stack. We have also hired a devops to help us take our server infrastructure
to the next level.

- Jordi Baylina and the team at [DappNode](https://twitter.com/DAppNODE) [deployed
the first Aragon Package Manager](https://twitter.com/izqui9/status/974203914659729408)
Registry in the Ethereum mainnet, making it the first mainnet live Aragon DAO.

#### Standards

- [ERC900](https://github.com/ethereum/EIPs/pull/900) has been **merged!**:
[http://eips.ethereum.org/EIPS/eip-900](http://eips.ethereum.org/EIPS/eip-900)

#### Events

- Attended and presented at **[EthCC](https://ethcc.io/)** in Paris, which was an incredible conference.
So good to catch up with friends and fellow buidlers. Presentation video:
[https://www.youtube.com/watch?v=ik1VlTgD53w](https://www.youtube.com/watch?v=ik1VlTgD53w)

- Spoke at [Madrid Blockchain for Good rocks](https://www.meetup.com/blockchain4goodSP/events/247991158/), Google Crypto Meetup (private)

- Helped organize Aragon's presence in an upcoming [tour around Asia with other
Ethereum projects](http://ethtour.asia/) in Europe. Tour will happen April 15th-May 6th, more details will follow!

#### Audits and bug bounty

- We have been working on [improving aragonOS](https://github.com/aragon/aragonOS/issues?utf8=✓&q=is%3Aissue+label%3A%22audit%3A+whg%22+) and [aragon-apps](https://github.com/aragon/aragon-apps/issues?utf8=✓&q=is%3Aissue+label%3A%22audit%3A+whg%22+)
based on WHG feedback. Our fixes will be now reviewed by them again and a final
report will be produced.

- Details of the second audit are almost finalized, audit will have already
begun by the time these words are being read!

- A live bug bounty will begin soon encouraging people to break Aragon's first
mainnet DAO.

### Next

- Deploy Aragon's own DAO to the mainnet and start doing payroll with it
- Help with Aragon Network whitepaper v2 and continue Network prototyping
- Help [District0x](https://blog.district0x.io/introducing-district-staking-3bf1fbc092ce)
and Status prototype their future Aragon mainnet deployments
- Start [Aragon Core](https://aragon.one/core) live bug bounty in the mainnet
- Coordinate audit #2 and finalize audit #1
- Offsite #2 and [Asian Tour with other European projects](http://ethtour.asia/)!

repository: serejandmyself/aragon-wiki

repo_name: serejandmyself/aragon-wiki


text:
+++
date = "2017-04-30T01:36:43-04:00"
title = "JavaFX Overview"
draft = true

[params]
  scripts = [
  "https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js",
    "https://cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js",
    "https://cdnjs.cloudflare.com/ajax/libs/raphael/2.2.7/raphael.min.js",
    "https://cdnjs.cloudflare.com/ajax/libs/js-sequence-diagrams/1.0.6/sequence-diagram-min.js"
  ]

+++

# JavaFX Overview

I find that I often need to reference some aspect of JavaFX when discussing other aspects of
Dex, so I decided to put it all together (hopefully coherently) in one place.

## History

I am always fascinated by how things evolved.  Learning the history of a thing drives
a deeper understanding much like learning Latin helps one understand other languages
with greater depth and appreciation.

**Click Image For Live Version**

[![Java FX Timeline](/blog/2017/javafx_overview/javafx_timeline.png)](/blog/2017/javafx_overview/javafx_timeline.html)

### The Early Years

In the early years, JavaFX evolved organically as a project known as F3.

#### F3: Form Follows Function

JavaFX is rooted in a declarative Java scripting language called Form Follows Function, or
 F3 for short.  F3 was originally conceived and implemented in 2005 by Chris Oliver while
 working at SeeBeyone; a company developing business integration software.

Chris took a look at the state of rich UI frameworks such as Adobe Flash. Adobe Flash was based
around XML and a dialect of JavaScript known as ActionScript.

Chris had strong feelings against using XML should not be used as a programming language, but
borrowing concept from Flash; F3 was born.

F3 provided Netbeans and Eclipse plugins which provided features such as as-you-type
valiation, code-completion, syntax highlithing and hyperlink navigation.  It also supported Swing,
Java2D.  Additionally, F3 could translate most of the SVG specification
into itself.

F3 allowed for the GUI to be expressed as a script.  Here is an example:

```javascript
import f3.ui.\*;
import f3.ui.canvas.\*;
import f3.ui.filter.\*;

Canvas {
    content: Text {
        x: 20
        y: 20
        content: "Welcome to F3"
        font: Font { face: VERDANA, style: [ITALIC, BOLD], size: 80 }
        fill: LinearGradient {
            x1: 0, y1: 0, x2: 0, y2: 1
            stops:
            [Stop {
                offset: 0
                color: blue
            },
            Stop {
                offset: 0.5
                color: dodgerblue
            },
            Stop {
                offset: 1
                color: blue
            }]
        }
        filter: [Glow {amount: 0.1}, Noise {monochrome: true, distribution: 0}]
    }
}
```

Which would yield:

![Welcome to F3](/blog/2017/javafx_overview/f3_demo.png)

It's strangely reminiscent of JSON (JavaScript Object Notation).

#### SUN Microsystems Acquires SeeBeyond

SeeBeyond was acquired by SUN Microsystems in September 2005 for $387 million USD in
a bid to promote their business integration capabilities.

While initially SUN seemed uninterested, this acquisition eventually helped bring introduce F3 to
innovators such as James Gosling; the father of Java itself.

**On November 21, 2006 James writes:**

"If you like scripting, you should take a look at Chris Oliver's weblog. He mostly discusses a scripting
 language that he's been working on called F3. It's mind-bendingly cool. It's a client-side scripting
  engine, rather than one of the usual server-side languages. It's designed for doing very graphically
  cool applications. He's got lots of demos in is blog, mostly directly runnable. In particular,
  you really must run through his interactive tutorial. The most mind-bendingly cool feature
 (and a little tricky to understand) is F3's dependency-based evaluation. Magic.
  Have some fun with it."

With evangelists such as James Gosling, good things were to follow.

#### JavaFX 1.x

On December 4, 2008, JavaFX officially releases Java FX 1.0.2.  JavaFX retains it's scripting focus through
the last of the 1.x releases; JavaFX 1.3.1 released on August 21, 2010.

During this time, JavaFX expands it's target platform base, adds many built in controls, layouts and charts.  CSS
controls, mobile support and many performance improvments are also added.

#### JavaFX 2.x

Java FX 2.0 is released on October 10, 2011.  Chris Oliver leaves Oracle in June 2011.  JavaFX, however,
has a bright future.

Most notable changes in the 2.x focus are:

  * JavaFX scripting is dropped in favor of a traditional Java API interface.
  * JavaFX mobile is dropped.
  * Oracle announces it's intent to Open Source JavaFX.
  * The underlying architecture is altered to leverage native, platform specific capabilities.
  Giving JavaFX applications near-native GUI performance.
  * FXML is introduced.

Incremental improvements occurred in point releases up to JavaFX 2.2 released on August 14, 2012.

#### JavaFX 8

In this release, JavaFX developers such as myself breathe a sigh of relief as JavaFX released sa part of Java.
No longer are our users required to download separate packages to enable JavaFX.

## Architecture

Ok, now lets delve into JavaFX architecture.  The following diagram depicts the main components at
a very high level.

![JavaFX Architecture](/blog/2017/headless_javafx/javafx_architecture.png)

### Scene Graph

### Graphics System

  * **Prism** - Processes render jobs.  It's Java's abstraction on top of things like DirectX,
  OpenGL, Java2D, etc...  This native accelleration is one of the reasons that JavaFX gives a
  much better user experience than Swing applications.
  * **Quantum Toolkit** - Ties Prism and Glass Windowing toolkit together and manages threading
  rules related to rendering and event handling.

### Windowing Tookit

#### Glass Windowing Toolkit

  * **Glass** - Glass is the lowest level in the JavaFX graphic stack.  Glass leverages the native
  platform for windowing and provides it's own resources when the native platform falls short. While
  AWT manages it's own event queue, Glass leverages the native event queue to schedule event usage.

  * **Web Engine** - The Web Engine is a full webkit based browser exposed as a JavaFX UI control
  which allows JavaFX to provide full web browsing capability.

repository: PatMartin/dex-site

repo_name: PatMartin/dex-site


text:
# pylut

A python module that builds, modifies, visualizes, and converts 3D LUTs from popular .cube and .3dl formats. The end goal for this module is to remove the obfuscation from proprietary LUT formats and provide a way to programmatically manipulate LUTs.

## Installation

	pip install pylut

And to upgrade:

	pip uninstall pylut
	pip install pylut

## Documentation

Very mediocre docs viewable at: http://pythonhosted.org/pylut/

## Usage

The idea is that the modifications to a LUT object are non-volatile, meaning that every modification method returns a new LUT object rather than changing the existing object. All sorts of great things can happen!

```python
from pylut import *
lut = LUT.FromLustre3DLFile("/path/to/file.3dl")
lut2 = LUT.FromLustre3DLFile("/path/to/file2.3dl")

print lut.ColorAtLatticePoint(1,2,1)
print lut.ColorAtInterpolatedLatticePoint(1.3,1.5,1.2)
print lut.ColorFromColor(Color(.002,.5,.2344))
print lut.ColorFromColor(Color.FromRGBInteger(14, 1000, 30, bitdepth = 10))

lut3 = lut.CombineWithLUT(lut2)

lut3 *= .5
lut3 -= LUT.FromIdentity(lut3.cubeSize)

lut3 = lut3.ClampColor(Color(0,0,.2),Color(0,0,.4))

lut3 = lut3.Resize(33)
lut3.ToNuke3DLFile("/path/to/destination.3dl")
```

## CLI

I also have a terrible CLI inside the bin folder.

Example:

	pylut some_lut.3dl --resize 17 --convert RCUBE

## Special Notes

In order to run

	lut.Plot()

You need to either be running OSX or have PyQt4 or PyGTK installed in order to visualize the cube.

## The Future

1. No clue.

## Contributing

1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request

repository: ZNemesis/pylut

repo_name: ZNemesis/pylut


text:
[![Community header](https://github.com/newrelic/opensource-website/raw/master/src/images/categories/Community_Project.png)](https://opensource.newrelic.com/oss-category/#community-project)

# newrelic-azure-functions
![GitHub release (latest SemVer including pre-releases)](https://img.shields.io/github/v/release/newrelic/newrelic-azure-functions?include_prereleases) [![Known Vulnerabilities](https://snyk.io/test/github/newrelic-experimental/newrelic-azure-functions/badge.svg?targetFile=package.json)](https://snyk.io/test/github/newrelic-experimental/newrelic-azure-functions?targetFile=package.json)

This repository contains functions to collect and forward logs from Microsoft Azure Blob Storage and Event Hubs.

## Configuration

For setup instructions, click on the name of the function you wish to configure below.

 | Function | Description | Data Sources |
| -------------| ----------- | -------------- |
|[New Relic Event Hub Function](EventHubForwarder)| Collects and forwards log data from Azure Event Hubs to New Relic Logs. |

[Azure Activity and Resource Logs](https://docs.microsoft.com/en-us/azure/azure-monitor/platform/resource-logs-stream-event-hubs)

[Azure Active Directory](https://docs.microsoft.com/en-us/azure/active-directory/reports-monitoring/tutorial-azure-monitor-stream-logs-to-event-hub)

|
|[New Relic Azure Blob Storage Function](BlobForwarder) | Collects and forwards log data from Azure Blob Storage to New Relic Logs.|

[Azure App Service](https://docs.microsoft.com/en-us/azure/app-service/troubleshoot-diagnostic-logs#enable-application-logging-windows)

[Azure Web Server](https://docs.microsoft.com/en-us/azure/app-service/troubleshoot-diagnostic-logs#enable-web-server-logging)

 |

## Contributing

Contributions to improve newrelic-azure-functions are encouraged! Keep in mind when you submit your pull request, you'll need to sign the CLA via the click-through using CLA-Assistant. You only have to sign the CLA one time per project.
To execute our corporate CLA, which is required if your contribution is on behalf of a company, or if you have any questions, please drop us an email at<EMAIL_ADDRESS>

## Community

New Relic hosts and moderates an online forum where customers can interact with New Relic employees as well as other customers to get help and share best practices. Like all official New Relic open source projects, there's a related Community topic in the New Relic Explorers Hub: [Log forwarding](https://discuss.newrelic.com/tag/log-forwarding)

## A note about vulnerabilities

As noted in our [security policy](../../security/policy), New Relic is committed to the privacy and security of our customers and their data. We believe that providing coordinated disclosure by security researchers and engaging with the security community are important means to achieve our security goals.

If you believe you have found a security vulnerability in this project or any of New Relic's products or websites, we welcome and greatly appreciate you reporting it to New Relic through [HackerOne](https://hackerone.com/newrelic).

If you would like to contribute to this project, review [these guidelines](https://opensource.newrelic.com/code-of-conduct/).

## License
newrelic-azure-functions is licensed under the [Apache 2.0](http://apache.org/licenses/LICENSE-2.0.txt) License.

repository: atipparaju/newrelic-azure-functions

repo_name: atipparaju/newrelic-azure-functions


text:
# Filters
[[toc]]

To creates default dropdown selectors in the heading row
```go
	sheet.AutoFilter("A1:A10")
```

repository: miscoler/xlsx

repo_name: miscoler/xlsx


text:
[//]: # (!!! Open README.html for rendered page !!!)

# RideShare

* A web application to manage taxi ridesharing using Java Servlets, Python, AngularJS and Machine Learning.
* The application has 3 user roles: *Rider/Customer*, *Driver*, *Admin*.
* Riders/Customers can book individual or shared taxi rides, cancel rides & rate drivers.
* Drivers can cancel rides & rate riders.
* Riders can view data like day-wise booking and cancellation, rides taken from zip codes, rating etc. on their dashboard.
* Drivers can view data like day-wise number of rides, day-wise earnings, zipcode-wise pickups & drops, rating etc. on their dashboard.

-----

### Total Lines of Code

- Lines of code for AngularJS UI              : **2,972**
- Lines of code for Java backend              : **2,290**
- Lines of code for Fare Estimate ML Modeling : **331**
- Lines of code for Python Fare API           : **82**

**Total Lines of Code = *5,675***

-----

### Technologies used in the application

***Topics from Assignments:***

- Java Servlets
- HTML & CSS
- MySQL Database
- MySQL CRUD Operations
- Application User Roles (Rider/Driver/Admin)
- Data Analytics & Visualizations
- Python
- Jupyter Notebooks
- JavaScript

***Others:***

- [Google Maps, Places & Distance Matrix APIs](https://developers.google.com/maps/documentation)
- [REST API](https://restfulapi.net/)
- [AngularJS](https://angular.io/) & [TypeScript](https://www.typescriptlang.org/)
- [Dask](https://dask.org/) for handling large amount of data (100 million records which don't fit in memory) and extraction useful data from the said data.
- [Numpy](https://numpy.org/), [Scipy](https://www.scipy.org/) & [Pandas](https://pandas.pydata.org/) for Data - Cleaning & Analysis.
- [scikit-learn](https://scikit-learn.org/stable/) for Machine Learning Model - Selection, Creation & Evaluation.
- [RandomForestRegression](https://medium.com/datadriveninvestor/random-forest-regression-9871bc9a25eb) - machine learning algorithm to estimate fare for a ride based on the distance, duration (from google distance matrix api) & number of perople sharing the ride.

-----

### Dataset used for the application

The Chicago City Data Portal's **[Transportation Network Providers - Trips](https://data.cityofchicago.org/Transportation/Transportation-Network-Providers-Trips/m6dm-c72p)** dataset has been used for this application. The dataset contains ***100,717,116*** records of ridesharing trips, starting November 2018, reported by Transportation Network Providers (sometimes called rideshare companies) to the City of Chicago as part of routine reporting required by ordinance. It contains trip start & end times, trip miles, trip total, pickup areas and many more informations for each trip.

From this dataset, we took 1 million records with only [Trip Miles, Trip Total, Shared Trip Authorized, Trips Pooled] columns using random sampling. This was done as the 100 million records did not fit into memory and the random sampling feature of pandas gives a very good sub sample of a dataset with same mean, variance & standard deviation.

-----

### Requirements

- [Java >= 11.0.4](https://aws.amazon.com/corretto/)
- [Python >= 3.7.5](https://docs.conda.io/en/latest/miniconda.html)
- [Tomcat Server 7.0.34](http://www.coreservlets.com/Apache-Tomcat-Tutorial/tomcat7-files/tomcat-7.0.34-preconfigured.zip) (with CORS filter enabled)
- [Node.js == 8.16.2](https://nodejs.org/dist/latest-v8.x/)
- [MySQL >= 8.0.18](https://dev.mysql.com/downloads/)
- Java Dependencies: **`servlet-api.jar`, `mysql-jdbc-5-bin.jar`, `gson-2.6.2.jar`** (Already present in **[lib](server/rideshare/WEB-INF/lib/)**)
- Python Dependencies: **`pandas`, `scikit-learn`, `joblib`, `flask`, `flask-cors`** (See **[requirements.txt](fare_estimation/requirements.txt)**)
- JavaScript Dependencies: See **[package.json](ui/package.json)**

-----

### Deploying the application

#### 1. Create MySQL Database User, Schema and Populate Data

Assuming that MySQL is installed and the server is running...

- Create the RideShare MySQL User. (Login to mysql shell as root `$ mysql -u root -p`)

    ```sql
    mysql> CREATE USER 'rideshareAdmin'@'localhost' IDENTIFIED BY 'rd@123';
    mysql> GRANT ALL PRIVILEGES ON * . * TO 'rideshareAdmin'@'localhost';
    mysql> FLUSH PRIVILEGES;
    mysql> \q
    ```
- Import the database schema and data from the dump file. (Database dump file: [rideshare_db_dump.sql](server/rideshare_db_dump.sql))

    ```bash
    $ mysql -u rideshareAdmin -prd@123 < server/rideshare_db_dump.sql
    mysql: [Warning] Using a password on the command line interface can be insecure.
    ```

*(Make sure the mysql `bin` folder is in PATH)*

#### 2. Enable [Cross-Origin Resource Sharing](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) (CORS) in Tomcat Server

Cross-Origin Resource Sharing (CORS) is a mechanism that uses additional HTTP headers to tell browsers to give a web application running at one origin, access to selected resources from a different origin. A web application executes a cross-origin HTTP request when it requests a resource that has a different origin (domain, protocol, or port) from its own.

Reference: https://tomcat.apache.org/tomcat-7.0-doc/config/filter.html#CORS_Filter

* Copy the JAR files in **`tomcat_cors_filters` (see [tomcat_cors_filters.zip](tomcat_cors_filters.zip))** to the **`lib`** folder in tomcat directory.

    ```bash
    $ unzip tomcat_cors_filter.zip
    $ cp tomcat_cors_filter/*.jar <path_to_tomcat_server_folder>/lib/
    ```

* Open the **`web.xml`** config file located in the **`conf`** folder in tomcat server directory & add the following lines inside **`<web-app>`** tag:

    ```xml
    <filter>
        <filter-name>CorsFilter</filter-name>
        <filter-class>org.apache.catalina.filters.CorsFilter</filter-class>
    </filter>
    <filter-mapping>
        <filter-name>CorsFilter</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>
    ```

#### 3. Install Python and dependency packages

2 Ways:

1. Virtual environment with python and package creation using conda.
2. Standalone python installation and package installation using pip.

***Create Virtual Environmnet with python3 and required packages***

Environment File: [rideshare.yml](rideshare.yml)

Assuming that [Miniconda/Anaconda](https://docs.conda.io/en/latest/miniconda.html) (python-3) is installed and working as expected:

```bash
# Load conda base environment first
$ source <miniconda-installation-path>/bin/activate

# Create the virtual environment using the environment YAML file
(base) $ conda env create -f rideshare.yml

# Activate the new environmnet
(base) $ conda activate rideshare

(rideshare) $
```

***-or-***

***Standalone python installation and package installation using pip.***

Assuming that python 3 has been installed:

Requirements File: [requirements.txt](fare_estimation/requirements.txt)

```bash
$ python --version
Python 3.6.8

$ python -m pip install -U -r fare_estimation/requirements.txt
```

#### 4. Install Node.js and javascript packages

Install **Node.js** (https://nodejs.org/en/)

Then, assuming that you are currently inside the folder **`ui`** in RideShare and nodejs and npm are added to PATH:

```bash
# Install the javascript packages using npm
$ npm install
```

#### 5. Copy the Java Server Code & required dependency JAR files to Tomcat

Server Source Code Folder: **[rideshare](server/)**

Dependency JAR Files: **[lib](server/rideshare/WEB-INF/lib/)**

Assuming you are currently in the **`RideShare`** folder

```bash
$ cp -rf server/rideshare <path_to_tomcat_server_folder>/webapps
$ cp -f server/rideshare/lib/* <path_to_tomcat_server_folder>/lib
```

#### 6. Start python server

Assuming you are currently in the **`RideShare`** folder

*If using conda: assuming rideshare enviroment is created as per step 3* & ***`base`*** conda environment is activated*

```bash
(base) $ conda activate rideshare
(rideshare) $ python fare_estimation/estimate_fare_api.py
```

***-or-***

*If using system python: assuming required packages have been installed as per step 3*

```bash
$ python fare_estimation/estimate_fare_api.py
```

*(Runs on port=555. Make sure port=5555 is free on your computer.)*

#### 7. Start the Tomcat server

```bash
$ <path_to_tomcat_server_folder>/bin/catalina.sh run
```

#### 8. Start node.js/angular server for UI

Assuming you are currently in the **`RideShare/ui`** folder and step 4 is done.

```bash
$ npm start
```

-----

### The application is now live and can be accessed @ http://localhost:4200/

-----

### Use of Machine Learning in the application:

#### Machine Learning has been used to predict/estimate the fare for a given trip based on: trip distance in miles (given by google distance matrix api), trip duration in seconds (iven by google distance matrix api), is the ride shared or individual (true/false) and number of riders in the trip (will be 1 in case of an individual ride).

#### The machine learning model creation and evaluation notebooks are located [here](fare_modeling/).

#### The machine learning algorithm used is *`RandomForestRegressor` implemented from scikit-learn.*

-----

### Contributors :: Team 4

#### 👨💻 Darshan Kodipalli

##### 📧 [dkodipalli<EMAIL_ADDRESS>◆ [darshan.kodipalli<EMAIL_ADDRESS>
#### 👨💻 Maneesh Divana

##### 📧 [mdivana<EMAIL_ADDRESS>◆ [maneeshd77<EMAIL_ADDRESS>
-----

repository: DarshanKodipalli/RideShare

gha_language: HTML

repo_name: DarshanKodipalli/RideShare


text:
---
layout: workshop
title: Testing for developers
description: ""
tags: [Testing, Moq, NUnit, Refactoring, SOLID, Design Patterns, Angular, dotnet, Angular, JavaScript ]
image:
  feature: workshops/testing-for-developers/logo.jpg
TheoryToPracticeRatio: 95
---

This training is design to make writing tests easier by:

- showing how good practices in writing code translate to easy to write tests
- learning how to **refactor** bad code to easily testable code.
- making sure attendees know the testing tools that they use daily
- organizing when to use which approach in testing different scenarios
- passing good practices that minimize test maintenance overhead
- learning when to remove tests

# <img src="/data/workshops/list.svg" class="listIcon" > Program

0. **Introduction**
1. **Testing**
    1. How to name tests
    2. How to write assertions
    3. Test organization
    4. DRY in tests
    5. Patterns and anti-patterns in tests.
        1. Inheritance vs. Composition
        2. Integration tests
    6. Data Driven testing
        1. How to set up and organize
        2. How to collect sample data from production and test environments
        3. Combinatorial testing
        4. Managing the number of test cases
        5. Evaluating the benefits and drawbacks
    6. Time saving features of testing frameworks ([NUnit](https://nunit.org/)/[Fluent Assertions](https://fluentassertions.com/))
2. **Mocking**
    1. Understanding how mocking works.
    2. When to mock and when not to.
    3. Mock verification.
    2. Time saver features of mocking frameworks ([Moq](https://github.com/moq)/[NSubstitute](https://nsubstitute.github.io/))
3. **Good code leads to easy tests**
    On a very simple program, attendees experience how good code allows moving from a complex 50 test to a 5 line one.
4. **SOLID as guidance on how to write testable code**
    We start from a sample "not too bad" application, and by applying SOLID principles and refactoring the code, we can write more straightforward tests that have a higher coverage.
5. **Design patterns as recipes to testable code**
    1. **Factory** and **Abstract Factory** design pattern - how to write less but more meaningful tests
    2. **Builder design pattern** - its usage in testing
    3. **Strategy design pattern** - separating object responsibilities leads to easy to test classes
    4. **State Machine design pattern** - rethinking design habits with OOP principles leads to readable and trivial to test code
    5. **Rules design pattern** - moving from nested ifs to a clean and testable code
    6. **Singleton design pattern** - the proper usage of one of the most common design patterns
6. **[Optional] Testing Angular**
    1. Unit tests
    2. Service testing
    4. Integration tests
    4. Component tests
    5. Component integration tests
    6. UI test
    7. Router tests


text:
# zomato-jquery-sdk

This is a Zomato's jQuery SDK to connect with the Zomato's API.

  - Just load the zomato.js along with jQuery library.
  - Initialize the Zomato's SDK with the key you got when you  signed up.
  - Execute the respective api function respective to the api handler specified in the Zomato's API.

### Version
1.0.0

### Dependencies

This library depends on jQuery library.

### Initialisation

Load the zomato.js:

```javascript
Zomato.init("<YOUR-ZOMATO-API-KEY>");
```
For example

```javascript
Zomato.init("8c2run923ur9n23ur92nc93uer8932ue"); //its a fake one ;-)
```

### Geocode

If you want to find nearby restaurants based on your location co-ordinates, here is the function to get the JSON formatted data. The number of entries are limited to 10 by default.
```javascript
Zomato.geocode({latitide:<latitude co-ordinate>, longitude:<longitude co-ordinate>},function(restaurants){
    //do your logic for restaurants data.
},function(error){
    //on error here is the logic for on error
})
```

### Restaurant details

If you want to get all the details regarding a particular restaurant, here is the function to access the /restaurant API handle.
```javascript
Zomato.restaurant(<restaurant_id>,function(restaurant){
    //do your logic for restaurant's data.
},function(error){
    //on error here is the logic for on error
})
```

### Todos

 - Add more functions for more API handles
 - Create a pure Javascript library

License
----

MIT

**Free Software, Hell Yeah!**


text:
# modules

Add Graphcool Modules to extend your project 🎁

## Getting Started

```sh
npm install -g graphcool
graphcool init
graphcool add modules/authentication/github
```

## Other resources

* [Graphcool Functions ⚡](https://github.com/graphcool-examples/functions)
* [Scripts 📝](https://github.com/graphcool-examples/scripts)
* [Schemas 🗒](https://github.com/graphcool-examples/schemas)

repository: marktani/modules

repo_name: marktani/modules


text:
---
hrs_structure:
  division: '1'
  volume: '4'
  title: '13'
  chapter: '212'
  section: 212-6
type: hrs_section
tags:
  - Government
menu:
  hrs:
    identifier: HRS_0212-0006
    parent: HRS0212
    name: '212-6 Establishment, operation, and maintenance of zone'
weight: 38035
title: 'Establishment, operation, and maintenance of zone'
full_title: '212-6 Establishment, operation, and maintenance of zone'
---
**§212-6 Establishment, operation, and maintenance of zone.** Any public corporation authorized pursuant to this chapter to make an application and whose application is granted pursuant to the terms of the Act of Congress may establish, operate, and maintain the foreign-trade zone:

(1) Subject to the conditions and restrictions of the Act of Congress;

(2) Under the rules and regulations, and for the period of time that may be prescribed by the foreign-trade zones board established by the Act of Congress to carry out the provisions of the Act. [L 1963, c 7, §7; Supp, §98T-7; [HRS §212-6](/title-13/chapter-212/section-212-6/)]

Attorney General Opinions

Application of various state taxes to foreign-trade zone activities. Att. Gen. Op. 64-52.

repository: SamMade/BlueAndKrabby

repo_name: SamMade/BlueAndKrabby


text:
# AutoSwap
![DogeCash Logo](https://dogec.io/assets/images/logo.svg)

Swap coins from 1 chain to another using explorer api call [Only suitable for Dogecash explorer,unless the explorer has a getalladdrs call implemented]

# Prerequisites
- getalladdrs call which is top100 call but with no limit
- old daemon and new daemon to swap to
- New daemon balance should match current supply to be swapped
- nodejs & npm

# How to use
- First do npm install
- setup env vars in .env file
- run node blacklisttotal.js to get blacklist amount and other info if needed
- run node index.js to swap coins from old chain to new chain via rpc

repository: dogecash/autoswap

gha_language: JavaScript

repo_name: dogecash/autoswap


text:
# open-source-libraries-c

All my created and ported libraries will be open source for the common usage.

## Guidelines

- Usages of these are provided in the respective **ReadMe Files** inside

## Contents

### MCU

- Added Microchip's BM62
- Added EEPROM AT24C32
- Added MPU9250
- Added STM32 Peripherals
  - GPIO
  - I2C
  - ISR Timer
  - IWDG
  - RTC
  - Timer
  - USART

### Algorithms

- Added Data structures
  - Ring buffer
  - Queue
- Added Low Pass Filter
  - IIRFilter
- Memory
  - Storage Memory Driver (For a simple wear levelling)
- Added Quaternion

### Changelogs

#### 0.0.1

- Updated readme for memory based libraries.

#### 0.0.2

- Updated **Storage** wear levelling algorithm to use less codespace and easy flow for storing configurations each 32 Bytes long based on logical partitioning

repository: aninda-ghosh/open-source-libraries-c

branch_name: refs/heads/main

repo_name: aninda-ghosh/open-source-libraries-c


text:
# mac-setup
automated setup of a Mac with basic software

## Execute / Install
```
$ curl -fsSL https://raw.githubusercontent.com/pjungermann/mac-setup/master/mac-setup.sh -o mac-setup.sh
./mac-setup.sh {options}
```

Options:
* `[-b|--use-branch {branch}]` - Branch from this repository to use when selecting the default Brewfile.
* `[-f|--brewfile {source-brewfile}]` - Source Brewfile. By default, the one in this repository.
* `[-u|--update-brewfile]` - Whether the local Brewfile should be overwritten with the latest state of the source.
* `[--no-global]` - By default, we use the global location ~/.Brewfile as installation destination.
  This option disables this and uses a separate location.
* `[--no-upgrade]` - Applies the same option to the brew command.

## Installed Software
* Xcode Command Line Tools
* [Oh My Zsh](https://ohmyz.sh/) - shell
  * activate some standard plugins (see `plugins` in `~/.zshrc` as well as `~/.oh-my-zsh/plugins/`)
* [Homebrew](https://brew.sh/) - package manager
  * Any software required at the `Brewfile`.
    * Includes: [mas](https://github.com/mas-cli/mas) - CLI for the Mac App Store
* [asdf](https://asdf-vm.com/) - Manage multiple runtime versions with a single CLI tool.
  * plugins (incl. latest version):
    * gradle
    * groovy
    * java _(corretto)_
    * maven
    * nodejs
    * ruby

repository: pjungermann/mac-setup

gha_language: Shell

repo_name: pjungermann/mac-setup


text:
# ngx-quicklink

[quicklink](https://github.com/GoogleChromeLabs/quicklink) implementation for Angular. It provides router preloading strategy which automatically downloads the lazy-loaded modules associated with all the visible links on the screen.

## How it works

Quicklink attempts to make navigations to subsequent pages load faster. It:

* **Detects `routerLink`s within the viewport** (using [Intersection Observer](https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API))
* **Waits until the browser is idle** (using [requestIdleCallback](https://developer.mozilla.org/en-US/docs/Web/API/Window/requestIdleCallback))
* **Checks if the user isn't on a slow connection** (using `navigator.connection.effectiveType`) or has data-saver enabled (using `navigator.connection.saveData`)
* **Prefetches the lazy loaded modules** using Angular's prefetching strategy)

## Why

This project aims to be a drop-in solution for sites to prefetch links based on what is in the user's viewport. It also aims to be small (**~2KB minified/gzipped**).

## Usage

First you need to install the project:

```bash
npm i ngx-quicklink --save
```

After that import the `QuicklinkModule` to the `AppModule`, and use the `QuicklinkStrategy` as `preloadingStrategy` in the router's configuration. For example:

```ts
// ...
import { QuicklinkModule, QuicklinkStrategy } from 'ngx-quicklink';

@NgModule({
  declarations: [...],
  imports: [
    // ...
    QuicklinkModule,
    RouterModule.forRoot(routes, { preloadingStrategy: QuicklinkStrategy }),
  ],
  bootstrap: [...]
})
export class AppModule {}
```

If you want to add a route in the ignore list so that `ngx-quicklink` will not preload it use the `data` property:

```ts
export const routes: Routes = [
  {
    path: 'contact',
    loadChildren: import(() => './contact/contact.module').then(m => m.ContactModule),
    data: {
      preload: false
    }
  }
];

```

**Note that to make the module available in lazy-loaded modules as well you need to import it in a shared module and export it.** Look at [this commit](https://github.com/mgechev/angular-realworld-example-app-qucklink/commit/33ea101c7d84bb5ca086f107148bbc958659f83f) to see how `ngx-quicklink` is integrated in the [angular-realworld-example-app](https://github.com/gothinkster/angular-realworld-example-app).

## Debugging

**Not getting routes preloaded?** Most likely the problem comes from a missing import of the `QuicklinkModule`. The `QuicklinkModule` exports a `LinkDirective` which matches the `[routerLink]` selector. It'll hook into all your router links in the scope of the module and observe their visibility. If you've not imported the `QuicklinkModule` correctly, this directive will be missing and the quicklink preloading strategy will not work.

**How to verify Angular has made my links "quicklinks"?** Inspect a router link and check if it has `ngx-ql` attribute. If it does not, make sure you import `QuicklinkModule` in the module that defines the compilation context of the template where the router link is. Alternatively, if the `ngx-ql` attribute is there, but the prefetching does not work as expected, please open an issue.

## Polyfills

`ngx-quicklink`:

* Includes a very small fallback for [requestIdleCallback](https://developer.mozilla.org/en-US/docs/Web/API/Window/requestIdleCallback)
* Optionally requires `IntersectionObserver` to be supported (see [CanIUse](https://caniuse.com/#feat=intersectionobserver)). On older browsers `ngx-quicklink` preloads all links on the page. If you want to enable the `IntersectionObserver` behavior on older browsers you can use conditional polyfill loading:

```html
<script src="https://polyfill.io/v2/polyfill.min.js?features=IntersectionObserver"></script>
```

Alternatively, see the [Intersection Observer polyfill](https://github.com/w3c/IntersectionObserver/tree/master/polyfill).

## FAQ

*What's the difference between quicklink and ngx-quicklink?*

>quicklink prefetches the resource pointed by the `href` attribute of an anchor. This doesn't work for Angular because the value of the `href` attribute is not a JavaScript bundle but a path defined inside of the routing configuration. ngx-quicklink introduces some additional functionality to make the same strategy work well with Angular.

*Should I use [Guess.js](https://github.com/guess-js/guess) or ngx-quicklink?*

>The prefetching behavior of Guess.js would most likely be more accurate compared to ngx-quicklink, which will reduce the overfetching. Guess.js, however, may take a little more effort to setup. In case you don't want to integrate with the analytics of your website ngx-quicklink is the right choice for you.

## Developing & releasing

For a demo:

```shell
git clone git@github.com:mgechev/ngx-quicklink
cd ngx-quicklink && npm i
ng build --project ngx-quicklink
ng serve
```

To release first update the package version and after that:

```shell
npm run release
cd dist/ngx-quicklink
npm publish
```

## Contributors

[](https://github.com/mgechev) |[](https://github.com/apps/dependabot) |[](https://github.com/wKoza) |[](https://github.com/rolaveric) |[](https://github.com/thekiba) |[](https://github.com/Flyrell) |
:---: |:---: |:---: |:---: |:---: |:---: |
[mgechev](https://github.com/mgechev) |[dependabot[bot]](https://github.com/apps/dependabot) |[wKoza](https://github.com/wKoza) |[rolaveric](https://github.com/rolaveric) |[thekiba](https://github.com/thekiba) |[Flyrell](https://github.com/Flyrell) |

[](https://github.com/Niaro) |[](https://github.com/krzysztof-grzybek) |[](https://github.com/tarsinzer) |[](https://github.com/mehmet-erim) |[](https://github.com/Timebutt) |[](https://github.com/pshurygin) |
:---: |:---: |:---: |:---: |:---: |:---: |
[Niaro](https://github.com/Niaro) |[krzysztof-grzybek](https://github.com/krzysztof-grzybek) |[tarsinzer](https://github.com/tarsinzer) |[mehmet-erim](https://github.com/mehmet-erim) |[Timebutt](https://github.com/Timebutt) |[pshurygin](https://github.com/pshurygin) |

[](https://github.com/thomashuston) |[](https://github.com/Komock) |[](https://github.com/jlilly) |
:---: |:---: |:---: |
[thomashuston](https://github.com/thomashuston) |[Komock](https://github.com/Komock) |[jlilly](https://github.com/jlilly) |

## License

MIT

repository: mgechev/ngx-quicklink

repo_name: mgechev/ngx-quicklink


text:
# Description #

This cookbook provides shared message queue configuration for the OpenStack **Icehouse** reference deployment provided by Chef for OpenStack. The http://github.com/mattray/chef-openstack-repo contains documentation for using this cookbook in the context of a full OpenStack deployment. It currently supports RabbitMQ and will soon other queues.

# Requirements #

Chef 11 with Ruby 1.9.x required.

# Platforms #

* Ubuntu-12.04

# Cookbooks #

The following cookbooks are dependencies:

* openstack-common
* rabbitmq

# Usage #

The usage of this cookbook is optional, you may choose to set up your own messaging service without using this cookbook. If you choose to do so, you will need to provide all of the attributes listed under the [Attributes](#attributes).

# Resources/Providers #

None

# Templates #

None

# Recipes #

## server ##

- message queue server configuration, selected by attributes

## rabbitmq-server ##

- configures the RabbitMQ server for OpenStack

# Attributes #

* `openstack["mq"]["cluster"]` - whether or not to cluster rabbit, defaults to 'false'

The following attributes are defined in attributes/messaging.rb of the common cookbook, but are documented here due to their relevance:

* `openstack["endpoints"]["mq"]["host"]` - The IP address to bind the rabbit service to
* `openstack["endpoints"]["mq"]["scheme"]` - Unused at this time
* `openstack["endpoints"]["mq"]["port"]` - The port to bind the rabbit service to
* `openstack["endpoints"]["mq"]["path"]` - Unused at this time
* `openstack["endpoints"]["mq"]["bind_interface"]` - The interface name to bind the rabbit service to

If the value of the "bind_interface" attribute is non-nil, then the rabbit service will be bound to the first IP address on that interface.  If the value of the "bind_interface" attribute is nil, then the rabbit service will be bound to the IP address specified in the host attribute.

Testing
=====

Please refer to the [TESTING.md](TESTING.md) for instructions for testing the cookbook.

Berkshelf
=====

Berks will resolve version requirements and dependencies on first run and
store these in Berksfile.lock. If new cookbooks become available you can run
`berks update` to update the references in Berksfile.lock. Berksfile.lock will
be included in stable branches to provide a known good set of dependencies.
Berksfile.lock will not be included in development branches to encourage
development against the latest cookbooks.

License and Author
==================

|                      |                                                    |
|:---------------------|:---------------------------------------------------|
| **Author**           |  John Dewey<EMAIL_ADDRESS>                     |
| **Author**           |  Matt Ray<EMAIL_ADDRESS>                    |
| **Author**           |  Craig Tracey<EMAIL_ADDRESS>           |
| **Author**           |  Ionut Artarisi<EMAIL_ADDRESS>             |
| **Author**           |  JieHua Jin<EMAIL_ADDRESS>                |
|                      |                                                    |
| **Copyright**        |  Copyright (c) 2013, Opscode, Inc.                 |
| **Copyright**        |  Copyright (c) 2013, Craig Tracey                  |
| **Copyright**        |  Copyright (c) 2013, AT&T Services, Inc.           |
| **Copyright**        |  Copyright (c) 2013, SUSE Linux  GmbH.             |
| **Copyright**        |  Copyright (c) 2013, IBM Corp.                     |

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: Justin-chi/compass-adapters

repo_name: Justin-chi/compass-adapters


text:
Slidecast
=================

Litte utility to do a slideshow of a specific directory on a Chromecast.

Installation
=================

Clone the repository locally.

```
git clone <url>
```

Then, install the dependencies (in this case, just one: [pychromecast](https://github.com/balloob/pychromecast))

```
pip install -r requirements.txt
```

Usage
=================

Simply type:

```
python slidecast.py
```

Then, the usage will come up:

```
$ python slidecast.py
Usage: slidecast.py [options]

Options:
  -h, --help            show this help message and exit
  -f FOLDER, --folder=FOLDER
                        Folder to show
  -c CHROMECAST, --chromecast=CHROMECAST
                        Name of the Chromecast you want to interact with
  -p PORT, --port=PORT  Port to fire up the web server (default: 8000)
  -d DELAY, --delay=DELAY
                        Delay to dispay the pictures (default: 10s)
  -v, --verbose         Verbose mode

```

A way to use it:

```
$ python slidecast.py  -f /media/paul/689C63BQ9C53750B/photos/ -v -p 8088
Internal ip found: <IP_ADDRESS>
Scanning Chromecasts...
Serving Web server on port 8088
Using Chromecast Badaboum
temp_url: http://<IP_ADDRESS>:8088/DSCN0281.JPG
<IP_ADDRESS> - - [08/Dec/2016 17:21:51] "GET /DSCN0281.JPG HTTP/1.1" 200 -
temp_url: http://<IP_ADDRESS>:8088/DSCN0282.JPG
<IP_ADDRESS> - - [08/Dec/2016 17:22:01] "GET /DSCN0282.JPG HTTP/1.1" 200 -
temp_url: http://<IP_ADDRESS>:8088/DSCN0283.JPG
<IP_ADDRESS> - - [08/Dec/2016 17:22:11] "GET /DSCN0283.JPG HTTP/1.1" 200 -
temp_url: http://<IP_ADDRESS>:8088/DSCN0284.JPG
<IP_ADDRESS> - - [08/Dec/2016 17:22:21] "GET /DSCN0284.JPG HTTP/1.1" 200 -
temp_url: http://<IP_ADDRESS>:8088/DSCN0285.JPG
<IP_ADDRESS> - - [08/Dec/2016 17:22:31] "GET /DSCN0285.JPG HTTP/1.1" 200 -
temp_url: http://<IP_ADDRESS>:8088/DSCN0286.JPG
<IP_ADDRESS> - - [08/Dec/2016 17:22:41] "GET /DSCN0286.JPG HTTP/1.1" 200 -
```

The scripts detects the internal private IP, fires up a HTTP server (to serve the pictures to the Chromecast), lists the Chromecasts on the private network and picks the one you chose (or the only one on your network if that's the case) and interacts with it.

License
=================

I released this tool under MIT License. Fork it and have fun with it! Cheers

repository: PaulSec/slidecast

repo_name: PaulSec/slidecast


text:
## Weather Forecast

**A simple weather application to provide a worldwide weather forecast for cities**

![forecast](docs/images/forecast-app-example.png)

## Project setup

### Clone the repo

```shell
$ git clone https://github.com/Oscarz90/WeatherForecastApp.git
```

### Install the dependencies

```shell
WeatherForecastApp$ yarn install
```

[![asciicast](https://asciinema.org/a/268702.svg)](https://asciinema.org/a/268702)

### Compiles and hot-reloads for development

```
WeatherForecastApp$ yarn start
```

[![asciicast](https://asciinema.org/a/Y9nLs13ngZg3gwI4ndMWgNclJ.svg)](https://asciinema.org/a/Y9nLs13ngZg3gwI4ndMWgNclJ)

### Compiles and minifies for production

```
WeatherForecastApp$ yarn run build
```

[![asciicast](https://asciinema.org/a/2e6dRaMgKAFW2G8p87I78l2AW.svg)](https://asciinema.org/a/2e6dRaMgKAFW2G8p87I78l2AW)

### Run and serve it with a static server

```
WeatherForecastApp$ yarn global add serve
WeatherForecastApp$ serve -s build
```

[![asciicast](https://asciinema.org/a/268706.svg)](https://asciinema.org/a/268706)


text:
# OpenStreetMapXPlot.jl

Build status: [![Build Status](https://travis-ci.org/pszufe/OpenStreetMapXPlot.jl.svg?branch=master)](https://travis-ci.org/pszufe/OpenStreetMapXPlot.jl)

Test coverage: [![Coverage Status](https://coveralls.io/repos/github/pszufe/OpenStreetMapXPlot.jl/badge.svg?branch=master)](https://coveralls.io/github/pszufe/OpenStreetMapXPlot.jl?branch=master)

[Documentation ![](https://img.shields.io/badge/docs-latest-blue.svg)](https://pszufe.github.io/OpenStreetMapXPlot.jl/latest)

This is a plotting companion for the [OpenStreetMapX.jl](https://github.com/pszufe/OpenStreetMapX.jl) package.

The package provides to plotting mechanisms for map vizualization:

- `Plots.jl` with GR as a back-end
- plotting directly to `PyPlot.jl` (please note that due to slower painting speed this option is reasonable only for small maps up to few thousand nodes)

## Installation

The current version has been tested with Julia 1.3.1 and Julia 1.5.0

```julia
using Pkg
pkg"add OpenStreetMapX"
pkg"add OpenStreetMapXPlot"
```

## Usage

We will show a full scenario including routing. Let us start by preparing the data and calculating a sample route.

```julia
using OpenStreetMapX

pth = joinpath(dirname(pathof(OpenStreetMapX)),"..","test","data","reno_east3.osm")
m =  get_map_data(pth,use_cache = false);
import Random
Random.seed!(0);
pointA = point_to_nodes(generate_point_in_bounds(m), m)
pointB = point_to_nodes(generate_point_in_bounds(m), m)
sr = shortest_route(m, pointA, pointB)[1]
```

Once the map data is in the memory we can start plotting. Let us start with `Plots.jl` with a `GR` back-end (this is the recommended approach due to GR's plotting speed, however due to Julia compiling process *time-to-the-first-plot* is around one minute, while subsequent plots can be created within few seconds).

```julia
using OpenStreetMapXPlot
import Plots
Plots.gr()
p = OpenStreetMapXPlot.plotmap(m,width=600,height=400);
addroute!(p,m,sr;route_color="red");
plot_nodes!(p,m,[sr[1],sr[end]],start_numbering_from=nothing,fontsize=13,color="pink");
p
```

![](plot_image.png)

Now, let us paint the same route using the plain `PyPlot.jl` back-end.

```julia
using OpenStreetMapXPlot
import PyPlot
p=OpenStreetMapXPlot.plotmap(m,width=600,height=400,use_plain_pyplot=true);
addroute!(p,m,sr;route_color="red");
plot_nodes!(p,m,[sr[1],sr[end]],start_numbering_from=nothing,fontsize=13,color="pink");
```

![](plot_image_pyplot.png)

Note that when using `PyPlot.jl` in Atom, depending on your configuration you might need to add `PyPlot.display_figs()` to actually see the figure

#### Acknowledgments
<sup>This code is a major re-write of plotting functionality of [https://github.com/tedsteiner/OpenStreetMap.jl](https://github.com/tedsteiner/OpenStreetMap.jl) project.
The creation of this source code was partially financed by research project supported by the Ontario Centres of Excellence ("OCE") under Voucher for Innovation and Productivity (VIP) program, OCE Project Number: 30293, project name: "Agent-based simulation modelling of out-of-home advertising viewing opportunity conducted in cooperation with Environics Analytics of Toronto, Canada. </sup>

gha_language: Julia


text:
# Server Side API - Weather 4cast

  ## Description

  This project uses a free API to get the weather for any city when searched. The city will then be saved in localstorage and whne you revisit the page it will display as a button allowing you to search again

  Link for the deployed application: [Server Side API - Weather 4cast](https://github.com/EastonShaum/Server-Side-API)

  ## Credits

  Github: [eastonshaum](https://github.com/eastonshaum)
  Email<EMAIL_ADDRESS>
  ## License
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

  ---

  ## Badges

  ![badmath](https://img.shields.io/github/languages/top/nielsenjared/badmath)

  ## Contributing

  See the [Contributor Covenant](https://www.contributor-covenant.org/) for more information on how you can contribute.

repository: EastonShaum/Server-Side-API

repo_name: EastonShaum/Server-Side-API


text:
# ParcelableTest
A library making it easy to verify that your `Parcelable` implementations behave as expected when they are parceled and un-parceled.

## Usage
Extend `ParcelableTest` and provide an instance of your `Parcelable` as well as its `CREATOR`:
```java
public class MyParcelableTest extends ParcelableTest<MyParcelable> {

    @NonNull
    @Override
    protected MyParcelable newItem() {
        return new MyParcelable("Member variable value");
    }

    @NonNull
    @Override
    protected Parcelable.Creator<MyParcelable> itemCreator() {
        return MyParcelable.CREATOR;
    }
}
```

When you run `MyParcelableTest`, a test will parcel your provided instance and un-parcel it, and then assert that the 2 objects are equal before and
after.

## License
```
Copyright 2019 Backbase R&D B.V.

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: Backbase/ParcelableTest

gha_language: Java

repo_name: Backbase/ParcelableTest


text:
# Mongobrowser

The mongobrowser is a purely html and javascript based clone of [robomongo](https://robomongo.org/) bringing its core
features to the web. It requires a backend to send requests to. Two sample backends are included in this repo and you
might wanna take a look at [Graibomongo](https://github.com/RRZE-PP/grails-graibomongo), our grails implementation of
a more sophisticated backend.

It features a port of large parts of the C++-Code of the NodeJS mongo-shell therefore allowing you to do almost anything
in its shell you can do in the mongo-shell.

# Demo

![Recorded demo](https://raw.githubusercontent.com/RRZE-PP/mongobrowser/master/demo.gif)

# Development

1. Start a backend server (it is recommended to start an instance of
   [Graibomongo](https://github.com/RRZE-PP/grails-graibomongo)) and a `mongod` instance
2. Build the MongoNS namespace (see src/mongo-shell/README.md) `make -C src/mongo-shell/`
3. Open the `src/mongobrowser.html` in a browser instance with disabled web security (allowing XHR-Requests from a
   `file://`-url) (eg `chromium --user-data-dir=/tmp/ --disable-web-security src/mongobrowser.html`)
4. Set the MongoNS backend URLs to point to your backend via your browsers' js command interface:
   ```MongoNS.initServerConnection("http://localhost:8080/shell/initCursor",
		"http://localhost:8080/shell/requestMore",
		"http://localhost:8080/shell/runCommand")
	```

If you consider using another backend (e.g. the mongodb REST api) you can do so by overwriting the Connection Namespace
in `src/mongo-shell/port_connection.js`

# Deploying

Run make to build and minify a compact version of the code, a minified version will be put to `bin/`

repository: RRZE-PP/mongobrowser

repo_name: RRZE-PP/mongobrowser


text:
## Storage Manager Stub

The `class StorageManager` is too large and unwieldy to support unit testing, yet there's member variable of that type in each `Context`. This directory defines a stub class for `StorageManager` that allows testing with `Context` in cases that don't require anything but a stub.

### Override Headers

The name of the header may not change; they're fixed in other headers. The file `storage_manager_override` declares the class `StorageManagerStub` and puts that declaration into `storage_manager.h`. The file `storage_manager_declaration_override.h` specializes a template that has the effect of assigning the alias `StorageManager` to StorageManagerStub`.

### CMake support

In order to activate the override, the directory path must be modified to reach this directory so that the override header will be found on the include path. The file `storage_manager_override.cmake` defines an object library that sets up the include path.

### Stub Definition

The file `storage_manager_stub.cc` is empty, but is needed to define an object library for the overridden storage manager.

repository: TileDB-Inc/TileDB

branch_name: refs/heads/dev

repo_name: TileDB-Inc/TileDB


text:
<!---
Group:observation period
Name:OP01 Count number of people who have at least one observation period in the database that is longer than 365 days.
Author:Patrick Ryan
CDM Version: 5.0
-->

# OP01: Count number of people who have at least one observation period in the database that is longer than 365 days.

## Description
## Query
```sql
SELECT COUNT(DISTINCT person_ID) AS NUM_persons
FROM @cdm.observation_period op
WHERE op.observation_period_END_DATE - op.observation_period_START_DATE >= 365;
```

## Input

None

## Output

|  Field |  Description |
| --- | --- |
| Num_Persons | Number of patients who have at least one observation period in the database that is longer than 365 days |

## Sample output record

|  Field |  Value |
| --- | --- |
| Num_Persons | 105119818 |

## Documentation
https://github.com/OHDSI/CommonDataModel/wiki/

repository: mi-erasmusmc/QueryLibrary

repo_name: mi-erasmusmc/QueryLibrary


text:
# pic16f690-examples

The [PIC16F690](https://microchip.com/wwwproducts/en/PIC16F690) is an 8-bit microcontroller from Microchip. Here are some examples:

  * [System clock](#system-clock) - configure the clock
  * [GPIO](#gpio) - toggle GPIO pins
  * [Timer with interrupt](#timer-with-interrupt) - configure a timer to interrupt the processor

[PIC16F631/677/685/687/689/690 datasheet](http://ww1.microchip.com/downloads/en/DeviceDoc/40001262F.pdf)

### Install tools

We'll use ```sdcc``` to compile code and ```pk2cmd``` to load it into flash program memory.

Build SDCC from source since Debian does not package a version of SDCC that supports pic14 and pic16 ports because of license requirements by Microchip.

```
sudo apt-get install bison flex libboost-dev g++ gputils texinfo zlib1g-dev automake autoconf-archive libtool
svn checkout https://svn.code.sf.net/p/sdcc/code/trunk sdcc-code
cd sdcc-code/sdcc
./configure
make -j
sudo make install
```

Build pk2cmd from source since there is no Debian package.

```
sudo apt-get install libusb-dev
wget http://ww1.microchip.com/downloads/en/DeviceDoc/pk2cmdv1.20LinuxMacSource.tar.gz
extract pk2cmdv1.20LinuxMacSource.tar.gz
cd pk2cmdv1.20LinuxMacSource
make linux
sudo make install
sudo cp /usr/share/pk2/PK2DeviceFile.dat /usr/local/bin
```

### Run a program

Wire up the PICkit 2 to the PIC16F690.

![](https://i.postimg.cc/wjCZbywj/IMG-1332.jpg)

**Note**: a decoupling capacitor should be placed between Vdd and Vss.

Write a program ([empty.c](empty.c)) in C:

```c
#include <pic16f690.h>

void main(void)
{
        // Does nothing!
}
```

Compile and run it!

```
$ sdcc -mpic14 -p16f690 --stack-size 8 --use-non-free empty.c
message: Using default linker script "/usr/share/gputils/lkr/16f690_g.lkr".

$ pk2cmd -PPIC16f690 -Fempty.hex -M -A5.0 -T
PICkit 2 Program Report
26-11-2019, 19:49:07
Device Type: PIC16F690

Program Succeeded.

Operation Succeeded
```

**Note**: ```--stack-size 8``` is used because the PIC16F690 can store 8 addresses in its stack:

![](https://i.postimg.cc/zvP8LD8H/stack.png)

## System clock

![](https://i.postimg.cc/QMjw3GZ2/system-clock.jpg)

Let's use the internal oscillator at 8 MHz *and* output it on the CLKOUT pin ([system-clock-intosc.c](system-clock-intosc.c)):

```c
#include <pic16f690.h>
#include <stdint.h>

static __code uint16_t __at(_CONFIG) config =
        _INTOSC & _WDTE_OFF & _PWRTE_OFF & _MCLRE_OFF &
        _CP_OFF & _BOR_OFF & _IESO_OFF & _FCMEN_OFF;

void main(void)
{
        IRCF2 = 1; IRCF1 = 1; IRCF0 = 1;  // Fosc = 8 MHz
        SCS = 1;
}
```

FOSC<2:0> of the configuration word register is set to internal oscillator with CLKOUT (```_INTOSC```). The 8 MHz high frequency oscillator is configured via IRCF<2:0> of the OSCCON register. And, then the internal oscillator is configured by setting the SCS bit of the OSCCON register.

**Note**: take a couple minutes to read ```pic16f690.h```. It can be found here ```/usr/local/share/sdcc/non-free/include/pic14/pic16f690.h```.

**Investigate**: The datasheet is somewhat inconsistent about the difference between FOSC<2:0> and SCS. SCS appears to control the MUX that selects between external and internal oscillator, despite its definition, while functionality such as CLKOUT as configured in FOSC<2:0> still takes effect.

If we probe CLKOUT, we'll see a **2 MHz** square wave since CLKOUT is defined to be Fosc/4:

![](https://i.postimg.cc/BZYtd4HK/system-clock-intosc-scope1.png)

How long does it take to switch to 8 MHz?

![](https://i.postimg.cc/ZqsKXLyh/startup.png)

Holy smokes! **380 us** from power up!

## GPIO

The PIC16F690 has general purpose I/O pins which are grouped into three ports. TRISA, TRISB, and TRISC can be configured to specify whether a pin is input or output, and PORTA, PORTB, PORTC can be read to get the value of an input pin or written to set the value of an output pin.

**Note:** When using PORTA pins, ANSEL and ANSELH must be set to 0 to configure the pins as digital I/O. If the pin is configured as analog input, the digital I/O circuitry is disabled.

How fast can we toggle a GPIO pin?

[gpio1.c](gpio1.c)

```c
#include <pic16f690.h>
#include <stdint.h>

static __code uint16_t __at(_CONFIG) configword1 =
        _INTOSC & _WDTE_OFF & _PWRTE_OFF & _MCLRE_OFF &
        _CP_OFF & _BOR_OFF & _IESO_OFF & _FCMEN_OFF;

void main(void)
{
        IRCF2 = 1; IRCF1 = 1; IRCF0 = 1;  // Fosc = 8 MHz
        SCS = 1;

        // Disable analog input mode
        ANSEL = 0x00;
        ANSELH = 0x00;

        // Configure PORT I/O pins as output
        TRISA = 0x00;
        TRISC = 0x00;
        TRISB = 0x00;

        PORTA = 0x00;
        PORTB = 0x00;
        PORTC = 0x00;

        for (;;) {
                RC2 = 1;
                RC2 = 0;
        }
}
```

![](https://i.postimg.cc/JhJ0D8Zt/gpio1.png)

One loop iteration takes 6 instructions. Let's check the assembly (gpio1.asm):

```asm
_00106_DS_:
;       .line   27; "gpio1.c"   RC2 = 1;
        BANKSEL _PORTCbits
        BSF     _PORTCbits,2
;       .line   28; "gpio1.c"   RC2 = 0;
        BCF     _PORTCbits,2
        GOTO    _00106_DS_
```

If we look at section 2.2 Data Memory Organization of the PIC16F690 datasheet, we see that data memory is partitioned into four banks. The bank is selected by configuring RP<1:0> of the STATUS register. For example, to modify the OSCCON register, we must switch to Bank 1 first, and then write to address 0x8F.

BANKSEL is not an instruction, but an assembler directive. To see the complete disassembly, see the list file (gpio1.lst):

```asm
                                           _00106_DS_:
                                           ;    .line   27; "gpio1.c"   RC2 = 1;
0000e7   1283     bcf     0x03, 0x5             BANKSEL _PORTCbits
0000e8   1303     bcf     0x03, 0x6
0000e9   1507     bsf     0x07, 0x2             BSF     _PORTCbits,2
                                           ;    .line   28; "gpio1.c"   RC2 = 0;
0000ea   1107     bcf     0x07, 0x2             BCF     _PORTCbits,2
0000eb   28e7     goto    0x00e7                GOTO    _00106_DS_
```

Here we see that BANKSEL clears both RP bits in the STATUS register, which selects Bank 0. Notice the STATUS register is always at address 0x3 in each bank.

So... we don't need to switch banks every time the loop body executes... let's rewrite the loop in assembly [gpio2.c](gpio2.c):

```c
__asm
        banksel PORTC
loop:
        bsf PORTC, 2
        bcf PORTC, 2
        goto loop
__endasm ;
}
```

Now we should expect the body of the loop to take 4 cycles since BSF and BCF take 1 cycle each and GOTO takes 2 cycles:

![](https://i.postimg.cc/3xrJrpJS/gpio2.png)

With a couple extra NOPs we can get a 50% duty cycle square wave. However, it has a jitter of ~10ns and is ~1.1kHz faster than expected:

![](https://i.postimg.cc/901KL450/gpio3.png)

## Timer with interrupt

Timer0 is an 8-bit counter that can be configured to increment according to either an internal or external clock source. When the timer overflows from 0xFF to 0x00, an interrupt will be generated.

Example [timer-interrupt.c](timer-interrupt.c):

```c
#include <pic16f690.h>
#include <stdint.h>

static __code uint16_t __at(_CONFIG) configword1 =
        _INTOSC & _WDTE_OFF & _PWRTE_OFF & _MCLRE_OFF &
        _CP_OFF & _BOR_OFF & _IESO_OFF & _FCMEN_OFF;

void isr(void) __interrupt(0)
{
        T0IF = 0;  // Clear timer interrupt flag.

        RC2 = 0;
        RC2 = 1;   // Set RC2 high for one cycle.
        RC2 = 0;
}

void main(void)
{
        IRCF2 = 1; IRCF1 = 1; IRCF0 = 1;  // Fosc = 8 MHz
        SCS = 1;

        TRISC = 0x00;  // Configure PORTC pins as digital output.
        PORTC = 0x00;  // Output logic zero on PORTC pins.

        T0CS = 0;      // Use the internal instruction cycle clock (Fosc/4) as TMR0 clock source.
        PSA = 1;       // Assign the prescaler to the WDT so that it doesn't affect TMR0.

        INTCON = 0;    // Disable all interrupt enables and flags.
        GIE = 1;       // Global interrupt enable.
        T0IE = 1;      // Enable Timer0 interrupt.

        TMR0 = 0;      // Reset counter to 0.

        for (;;) {
                // Do nothing!
        }
}
```

![](https://i.postimg.cc/B65VvmgR/Capture.jpg)

From the list file we see the interrupt service routine located at address 0x4 in program memory with quite a few instructions for saving/restoring a some special function registers:

```asm
                                           ;    .line   8; "timer-interrupt.c"  void isr(void) __interrupt(0)
000004   00f2     movwf   0x72                  MOVWF   WSAVE
000005   0e03     swapf   0x03, 0x0             SWAPF   STATUS,W
000006   0183     clrf    0x03                  CLRF    STATUS
000007   00f1     movwf   0x71                  MOVWF   SSAVE
000008   080a     movf    0x0a, 0x0             MOVF    PCLATH,W
000009   018a     clrf    0x0a                  CLRF    PCLATH
00000a   00f0     movwf   0x70                  MOVWF   PSAVE
00000b   0804     movf    0x04, 0x0             MOVF    FSR,W
00000c   1283     bcf     0x03, 0x5             BANKSEL ___sdcc_saved_fsr
00000d   1303     bcf     0x03, 0x6
00000e   00ac     movwf   0x2c                  MOVWF   ___sdcc_saved_fsr
                                           ;    .line   10; "timer-interrupt.c" T0IF = 0;  // Clear timer interrupt flag.
00000f   1283     bcf     0x03, 0x5             BANKSEL _INTCONbits
000010   1303     bcf     0x03, 0x6
000011   110b     bcf     0x0b, 0x2             BCF     _INTCONbits,2
                                           ;    .line   12; "timer-interrupt.c" RC2 = 0;
000012   1107     bcf     0x07, 0x2             BCF     _PORTCbits,2
                                           ;    .line   13; "timer-interrupt.c" RC2 = 1;  // Set RC2 high for one cycle.
000013   1507     bsf     0x07, 0x2             BSF     _PORTCbits,2
                                           ;    .line   14; "timer-interrupt.c" RC2 = 0;
000014   1107     bcf     0x07, 0x2             BCF     _PORTCbits,2
                                           ;    .line   15; "timer-interrupt.c" }
000015   1283     bcf     0x03, 0x5             BANKSEL ___sdcc_saved_fsr
000016   1303     bcf     0x03, 0x6
000017   082c     movf    0x2c, 0x0             MOVF    ___sdcc_saved_fsr,W
000018   1283     bcf     0x03, 0x5             BANKSEL FSR
000019   1303     bcf     0x03, 0x6
00001a   0084     movwf   0x04                  MOVWF   FSR
00001b   0870     movf    0x70, 0x0             MOVF    PSAVE,W
00001c   008a     movwf   0x0a                  MOVWF   PCLATH
00001d   0183     clrf    0x03                  CLRF    STATUS
00001e   0e71     swapf   0x71, 0x0             SWAPF   SSAVE,W
00001f   0083     movwf   0x03                  MOVWF   STATUS
000020   0ef2     swapf   0x72, 0x1             SWAPF   WSAVE,F
000021   0e72     swapf   0x72, 0x0             SWAPF   WSAVE,W
                                           END_OF_INTERRUPT:
000022   0009     retfie                        RETFIE
```