text:
![pypi](https://img.shields.io/pypi/v/tuxdrive.svg)
![python](https://img.shields.io/pypi/pyversions/tuxdrive.svg)
![license](https://img.shields.io/github/license/prahladyeri/tuxdrive.svg)
![last-commit](https://img.shields.io/github/last-commit/prahladyeri/tuxdrive.svg)
![Status](https://img.shields.io/badge/status-stable-brightgreen.svg)
[![patreon](https://img.shields.io/badge/Patreon-brown.svg?logo=patreon)](https://www.patreon.com/prahladyeri)
[![paypal](https://img.shields.io/badge/PayPal-blue.svg?logo=paypal)](https://paypal.me/prahladyeri)
[![follow](https://img.shields.io/twitter/follow/prahladyeri.svg?style=social)](https://twitter.com/prahladyeri)

## Introduction

`tuxdrive` is a console based DIY google drive client.

![Logo](tuxdrive/logo_small.jpg)

## Installation

	pip install tuxdrive

Since this is a DIY (Do-it-yourself) app, you'll have to register your own app by going to the [Google Cloud Console](https://console.cloud.google.com) and then:

1. Enable Google Drive API.
2. Create credentials (make sure you choose "Desktop App").
3. Download the credentials json file and save it as `client_id.json` to your working folder.

Only then the program will be able to work. For more information on registering a Google app, you may [refer to this article](https://prahladyeri.com/blog/2016/12/how-to-create-google-drive-app-python-flask.html).

Notes:

- If you are a new developer on Google, you might see a prompt saying "This app isn't verified", so you must add a [security exception](https://raw.githubusercontent.com/prahladyeri/prahladyeri.com/gh-pages/uploads/google_app_no_street_cred.png) to verify it successfully.
- As of version 2.0.0, `pip` is the only supported installation method, the old DEB/RPM method is depreciated.

## Usage

`tuxdrive` has a command line interface to the google drive interface similar to traditional unix tools like `ftp` and `sftp` (though not as extensive and comprehensive yet!).

Once you start `tuxdrive` program, it will give you a `tux_drive>` prompt from which you can run the above commands. When you run `tuxdrive` the first time, it will open up the browser window and ask for permissions to access your google drive on your behalf. After that, you can start running commands. You can list your drive files using `ls` or `dir` command for example:

![Screenshot](tuxdrive/screenshot.png)

Similarly, you can run `push some_local_file.txt` to upload it to your drive, or `rcd my_drive_folder` to change the remote drive. Here is the entire command list:

	help (or ?): Shows this help facility.
	dir (or ls): Lists all files and folders on drive.
	!dir (or !ls): Lists all files and folders in current directory.
	get (or pull) <item>: Pulls the named file/folder from drive to current working directory.
	put (or push) <item>: Pushes the named file/folder from current working directory to drive.
	rm <item>: Delete the named file/folder on remote path.
	pwd: Print working directory (remote/drive).
	cd: Change working directory (remote/drive).
	lpwd: Print working directory (local).
	lcd: Change working directory (local).
	mkdir: Create a directory on remote path.
	list permissions <item>: Lists the permissions on specific file/directory.
	clear permissions <item>: Clears permissions on specific file/directory.
	share <item>: Shares the specific file/directory in remote drive publicly.
	share <item> <email>: Shares the specific file/directory in remote drive to specified email.
	exit: Exits this program.
	rdcache: Show remote directory mapping of id and folder paths.
	rfcache: Show remote files mapping of id and folder paths.

## License

`tuxdrive` is free and open source software. It is [MIT](https://opensource.org/licenses/MIT) licensed.

## Donation

Please consider donating if this tool has helped you in any way. You can also hire me through [upwork](https://www.upwork.com/freelancers/~01e977ff45b62e031c) or [fiverr](https://www.fiverr.com/prahladyeri) to get professional support and customization.

- [Donate through PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=JM8FUXNFUK6EU)
- [Donate through Patreon](https://www.patreon.com/prahladyeri)

repository: CNERic/tuxdrive

repo_name: CNERic/tuxdrive


text:
# Alpyne

The **A**ny**L**ogic-**Py**thon con**ne**ctor

This is a Python library for interactively running models exported from the RL experiment.

Currently, this library released as a **public beta** (so please excuse any rough edges). If you have problems or bugs, please file them in the `Issues` tab. For general talk or questions, there's the `Discussions` tab.

Full documentation (with background information, getting started guide, and class docs) can be found @ https://t-wolfeadam.github.io/Alpyne

Installation
------------
Alpyne supports Python 3.6+

Install this library running the following command in a terminal prompt: ``pip install anylogic-alpyne``.

Preparing an AnyLogic model
---------------------------
You can use *any* edition of AnyLogic (PLE, University, or Professional) with this library. However, be aware that limitations of the edition will still apply. For example, PLE users executing models which utilize industry-specific libraries have their runs limited to 1-hour simulation time.

You will need to setup your model with the following components.

1. RL experiment, with the Configuration, Observation, Action, and stopping conditions filled out, as per your specifications
2. A call to the RL experiment's ``takeAction`` method, at the moment you wish an action to be taken

To export the model, navigate to the properties of your RL experiment and click the option at the top to export it. If you do not see an option for Alpyne or generic 3rd parties, you may use the one for "Microsoft Bonsai".

Next Steps
----------
The API and overall workflow for Alpyne is intentionally similar to the AnyLogic Cloud. In your Python code, you will create a single Client object, passing a reference to where your exported model is located, in addition to setting other options. This object then gives you access to templates for the inputs/outputs of the model in addition to methods for creating new model runs, which can then be interacted with.

For more, see the [documentation page](https://t-wolfeadam.github.io/Alpyne), download the provided examples, or post in the Discussions tab.

license: MIT

repository: jfleonUOC/Alpyne

branch_name: refs/heads/main

extension: md

license_type: permissive

repo_name: jfleonUOC/Alpyne


text:
# Point Break - a Vancouver Island surfer's guide to great surfing
Point Break is all about getting you the info you need in order to enjoy the best of Vancouver Island surfing. Point Break offers user registration, where a user may select up to 10 of their favorite Vancouver Island beaches. Users will then receive notifications via email or text, depending on their preference, telling them when the weather conditions are just right for a great day of surfing.

Eliminating the need to check multiple sources frequently to get weather information on different Vancouver Island beaches, Point Break has already done the hard work for you by collecting and combining the best local surf information.

Point Break offers simplified surf forecasts on their home page so you can have a heads-up on what the swell and wind will be like up to six days in advance. We've included a star-rating system so that you can interpret the forecast more easily if you're new to reading these types of forecasts.

Point Break presents a simple, clean user interface for quick and easy navigation. Stop checking multiple weather sources every day. Sign up, sit back, and allow Point Break to let you know when to grab your board and go.

## Visit
We've deployed our app on Heroku! Please go to https://point-break-lhl.herokuapp.com/ to view it.

## Team Members
Point Break was completed as the final project for Lighthouse Labs, Sept. 2018. Team members who contributed to this project are:
- Cathleen Melendez (Database, user registration and user profile)
- Kenny Brown (Google Maps API, front-end design)
- Ryan White (Weather and notification APIs, surf forecast rendering)

## Demo

![Home](https://github.com/hellocathleen/react-app/blob/cathleen/public/screenshots/Home.png?raw=true)
* Register, log in, or view this week's forecasts for 10 of Vancouver Island's best beaches.

![Map](https://github.com/hellocathleen/react-app/blob/master/public/screenshots/Map.png?raw=true)
* Check the pins on the map to discover the locations of Vancouver Island beaches

![Forecast](https://github.com/hellocathleen/react-app/blob/cathleen/public/screenshots/Forecasts.png?raw=true)
* Check the swell and wind conditions up to six days in advance for Vancouver Island beaches. Click the arrow to expand the window and see the whole week's forecast.

![Register](https://github.com/hellocathleen/react-app/blob/cathleen/public/screenshots/Register.png?raw=true)
* Register so you can receive notifications for your favorite Vancouver Island beaches.

![Profile](https://github.com/hellocathleen/react-app/blob/cathleen/public/screenshots/User%20Profile.png?raw=true)
* Manage your favorite beaches with the simple add and delete capability, and change notification preference or turn notifications off in your user profile page. You can always come back and turn them back on when you're ready to receive surf notifcations again!

### Dependencies

* React
* React Google Maps
* Axios
* [babel-loader](https://github.com/babel/babel-loader)
* [webpack-dev-server](https://github.com/webpack/webpack-dev-server)

repository: hellocathleen/react-app

branch_name: refs/heads/master

gha_language: JavaScript

gha_license_id: MIT

repo_name: hellocathleen/react-app


text:
jquery_menu_aim-rails
================================================================================

[jQuery-menu-aim](https://github.com/kamens/jQuery-menu-aim) packaged for the
Rails asset pipeline.

Usage
--------------------------------------------------------------------------------

Add the gem to your Gemfile:

    gem 'jquery_menu_aim-rails'

Load the library within an asset manifest such as `application.js`:

    //= require jquery_menu_aim-rails/jquery.menu-aim

If you've included the gem in your Gemfile, Bundler will generally take care of
`require`ing the necessary files, but if for some reason you need to manually
`require` the gem:

    require 'jquery_menu_aim/rails'

Versioning
--------------------------------------------------------------------------------

The [jQuery-menu-aim](https://github.com/kamens/jQuery-menu-aim) project
has no versioned releases*. The following table indicates which
version of the JS file (indicated by commit ID) is included with each version
of the gem.

| Gem Version | Commit ID |
| ----------- | --------- |
| 1.0.0       | [da3cb65](https://github.com/kamens/jQuery-menu-aim/commit/da3cb657f36a1876d6a34514ad1fb81f1dd2433c) |

*The project's readme states the current version is 1.1, however, it is
unclear how releases are managed and how users of the software can know which
version of the software they are using. This project therefore treats
jQuery-menu-aim as having no versioned releases.

repository: chriscressman/jquery-menu-aim-rails

repo_name: chriscressman/jquery-menu-aim-rails


text:
# Microsoft Azure AppInsights

All the calls to `log.X` push trace events to AppInsights. Those are the events you can't directly see on main AppInsigts page but can access from **Analytics** tab:

![Azure Appinsights Analytics Button](azure-appinsights-analytics-button.png)

The easiest way to get the events is to type a simple query in analytics:

![Azure Appinsights Analytics Query](azure-appinsights-analytics-query.png)

`ILog` interface has a few extra methods which AppInsights package redirects to a proper location withing the account:

## Application Events

Application events help to report something important and distinct happening in your application. Events are logged by a call:

```csharp
log.Event("EventName", new Dictionary<string, object>
{
	{ "param1", someValue },
	{ "param2", someValue }
});
```

You can watch application events in the AppInsight account from the Events tab:

![Azure Appinsights Analytics Events](azure-appinsights-analytics-events.png)

## Dependencies

Dependencies are external resources your application depends on. For instance, if you're calling to an external database this is a dependency. It's useful to track the dependency and know how long in takes to execute, which you can do with a following call:

```csharp
log.Dependency(
	"dependency type name",
	"dependency instance name",
	"operation name",
	TimeItTookInTicks);
```

You can see the dependencies on application map in AppInsights:

![Azure Appinsights Analytics Dependency](azure-appinsights-analytics-dependency.png)

## Metrics

Metrics are a convenient way to track application metrics. For example, if you application fetches messages for a massive queue you might want to monitor how many messages there are in queue at a given moment of time.

```csharp
log.Metric("queue size", ElapsedTicks);
```

You can view metrics in the "Metric Explorer" tab in AppInsights.

## Requests

Requests are usually mapped to incoming requests for your application. For isntance, for web services that would become an incoming http request:

```csharp
log.Request("GetProducts", time.ElapsedTicks);
```

repository: nblumhardt/logmagic

gha_language: C#

repo_name: nblumhardt/logmagic


text:
---
layout: post
title: My first post
image: /img/hello_world.jpeg
tags: [new, exciting]
---

This is my first post to my new website, which is built using the Beautiful Jekyll templates built by Dean Attali.

To quote:

> Beautiful Jekyll is a ready-to-use template to help you create an awesome Jekyll or GitHub Pages website quickly.

I owe a debt of gratitude to [Dean Attali](https://deanattali.com/), for providing this amazing site template, [Beautiful Jekyll](https://deanattali.com/beautiful-jekyll/).


text:
# Internationalization (i18n)

[Runtime i18n Example](./internationalization-(i18n)/runtime-i18n-example.html)

Currently, Nova supports static internationalization via the built-in Angular mechanisms, but we need to provide a solution for dynamic localization. We also need to provide Nova translations and find a way to keep them updated while maintaining a fast release cadence. We’ll be focusing on this in Q4 2019 and Q1 2020. This guide is intended to walk you through the process of configuring i18n in your application and managing dependency translations.

### Translating your app

Nova uses the standard Angular attributes for i18n:

`<nui-message type="info" i18n>Hello!</nui-message>`

[The official docs](https://angular.io/guide/i18n) are thorough, and should be used to learn how the attribute works.

As of Angular 8, code translations are not possible with google-only tools. The solution recommended by the community is [ngx-translate/i18n-polyfill](https://github.com/ngx-translate/i18n-polyfill), written by a former Google contractor on the Angular team. This polyfill is used inside Nova for controller-based translation.

### Creating translation files

Template-based strings can be extracted to a `messages.xlf` file with the `ng xi18n` command. This command will also output translations for any libraries that have i18n in their templates, like Nova.

The ngx-extractor command line tool will pull controller based translations out of you app, and add them to your existing `messages.xlf` file. The [official instructions](https://github.com/ngx-translate/i18n-polyfill#extraction) show you how to do this. Note that this tool will NOT pick up items in libraries, unlike the template based tool.

At this point, your app should have one file with a bunch of translations, and the Nova library. The Nova package includes .xlf files that it has extracted. This is shown below:

![Initial translation state](../assets/initial-translation-state.svg)

### Filtering out Nova translations

> This step is optional. You don't have to screen out Nova translations. However, you will have to re-translate Nova strings with your product.

Since you have one `messages.xlf` that contains most of your strings AND Nova template strings, you need to screen them out. There is a great in-house tool for this, [xliff-filter](https://bitbucket.solarwinds.com/projects/MSP-PE/repos/xliff-tools/browse). Running this tool will pull out all the Nova strings, leaving just your app's strings. Be aware that xliff-filter has to be run before ngx-extractor.
You may want to add a similar script to your `package.json`:
```
"generate-local-xliff": "ng xi18n && xliff-filter --config xliff-tools-filter.json && ngx-extractor -i src/**/*.ts -f xlf -o .tmp/messages.xlf",
```

### Creating copies of different languages

At this point, you have a single `messages.xlf` file that ONLY contains your app's strings. You could probably just take this file, translate it, and then pull it into your app. However, when you have to release version 2 of your app, it will get confusing what new things need to be translated, and what doesn't.

To prevent losing these already-translated strings, there are tools to alleviate this. [Xliff-tools](https://bitbucket.solarwinds.com/projects/MSP-PE/repos/xliff-tools/browse) has one called xliff-update. However, this tool has difficulties parsing some xml files. There is also a 3rd party tool, [xliff-merge](https://github.com/martinroob/ngx-i18nsupport) that does the same thing, which may be able to parse more files.
Both these tools function like this:
- Parse original `messages.xlf`
- Open language specific xlf files (like `messages.fr.xlf`)
- Determine (based on ID) which strings are in in the original file, but NOT in the language specific file
- Copy entry to language specific file

![Modified translation state](../assets/modified-translation-state.svg)

### Okay, so I have all these translation files, now what?

You'll first need to combine Nova translation files and your app translation files into one big file. There is another tool in xliff-tools for this, called xliff-concat. It will combine 2 xliff files into one. You also need to get those files into your app. [Angular has a guide how to do this](https://angular.io/guide/i18n#merge-the-completed-translation-file-into-the-app). You'll notice the first thing that Angular mentions is AoT vs JIT.  AoT is a much faster technology, but it does have a big drawback - all the templates that it uses are precompiled. This means that you have to recompile your app once for EACH language you support. You will also have to deploy the same number of apps.

Once you have decided on JIT vs, AoT, you'll need to load the translations into the app.  A convienient way to do this is via angular CLI and it's "environment" pattern.

In your `angular.json`:
```
"fileReplacements": [
  {
    "replace": "src/environments/environment.ts",
    "with": "src/environments/environment.prod.ts"
  }
```

`environment.prod.fr.ts`:

```
import { registerLocaleData } from '@angular/common';
import localeFr from '@angular/common/locales/fr';

registerLocaleData(localeFr);

declare const require: any;
export const translationLibrary = require(`raw-loader!../../dist/messages.fr.xlf`);
```

`app.module.ts`:
```
providers: [
    ...
    {provide: TRANSLATIONS_FORMAT, useValue: "xlf"},
    {provide: MISSING_TRANSLATION_STRATEGY, useValue: MissingTranslationStrategy.Warning},
    // {provide: LOCALE_ID, useValue: "fr" }, // needed if using JIT compiler
    {provide: TRANSLATIONS, useValue: translationLibrary}
    ...
],
```
Note that TRANSLATIONS_FORMAT and TRANSLATIONS providers must be declared. However, if you are not interested in i18n, you can set TRANSLATIONS to an empty string.  Example

## FAQ

__Why don't you just use [gettext](https://bitbucket.solarwinds.com/projects/APOLLO/repos/i18n-gettext/browse)?__

Gettext is a custom solution written for NovaJS. It has similar features to the built in Angular i18n. However, it has drawbacks - it breaks standard $translate interpolation, it is a custom solution, etc. However, the biggest factor is that Angular i18n hooks easily into Angular CLI, which allows easy, seamless testing with AoT.

__With AoT, do I really have to recompile once for each language? Seriously?__

Yes. This may change with the adoption of Angular's new renderer, Ivy.

__If I don't do controller translation, do I need the polyfill library?__

Yes, Nova uses this library for some of its logic.

__Why is this so complicated?__

At google, all translation is done in templates, and the most important thing is speed. So, they do not need controller-based translation, and the overhead of deploying one application per language is a good trade off.

repository: madelyneh/nova-ui

repo_name: madelyneh/nova-ui


text:
# Anaconda Python with Jupyter Notebook Server

## Additional Packages
* rfcde

## Set up

Pull image from dockerhub.com
```
pull_image rfcde
```

## Instructions

Anconda Python and Jupyter Notebook

### To start container:
```
start_dss rfcde [source_code_dir]
```
`source_code_dir`: optional parameter, if missing assumes current working directory.

### To launch web browser (MacOS only) or print port number to connect (AWS Linux)
```
launch_dss rfcde
```

### To stop conatiner:
```
stop_dss rfcde
```

### Limitations:
* Notebook authentican disabled.

gha_language: Shell


text:
---
templateKey: blog-post
title: KickBoxing
order: 5
date: 2019-05-01
description: The best Kickboxing program in Jackson Heights, NY!
thumbnail: /img/kick-AIS09142.jpg
home: true
tags:
  - Programs
---
- - -

# Kickboxing

## The best kickboxing program in Jackson Heights, NY!

• Kickboxing is a form of martial arts derived from karate. It borrows moves from multiple types of martial arts including full-contact karate, Muay Thai, and boxing.

• Although the name implies kicking as a priority, this type of martial art uses both hands and feet as points of contact. Kicks and punches are both used during kickboxing.

• Kickboxing involves lots of rapid movement and can easily increase your heart rate to a similar pace as running.

• This type of training is called high-intensity interval training and has been shown to be especially good for burning calories and increasing cardiovascular fitness.

- - -

![](/img/dsc03043.jpg)

![](/img/dsc00260.jpg)

![](/img/dsc03165.jpg)

![](/img/dsc03001.jpg)

![](/img/dsc00224.jpg)

![](/img/dsc03110.jpg)

![](/img/dsc03136.jpg)

- - -

gha_language: CSS


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

FT's dom delegate library is a simple, easy-to-use component for binding to events on all target elements matching the given selector, irrespective of whether anything exists in the DOM at registration time or not. This allows developers to implement the [event delegation pattern](http://www.sitepoint.com/javascript-event-delegation-is-easier-than-you-think/).

Delegate is developed by [FT Labs](http://labs.ft.com/), part of the Financial Times.

## Compatibility ##

The library has been deployed as part of the [FT Web App](http://app.ft.com/) and is tried and tested on the following browsers:

* Safari 5 +
* Mobile Safari on iOS 3 +
* Chrome 1 +
* Chrome on iOS 5 +
* Chrome on Android 4.0 +
* Opera 11.5 +
* Opera Mobile 11.5 +
* Firefox 4 +
* Internet Explorer 9 +
* Android Browser on Android 2 +
* PlayBook OS 1 +

## Installation ##

```
npm install dom-delegate
```

or

```
bower install dom-delegate
```

or

Download the [built version](http://wzrd.in/standalone/dom-delegate@latest).

## Usage ##

The script must be loaded prior to instantiating a Delegate object.

To instantiate Delegate on the `body` and listen to some events:

```js
function handleButtonClicks(event) {
  // Do some things
}

function handleTouchMove(event) {
  // Do some other things
}

window.addEventListener('load', function() {
  var delegate = new Delegate(document.body);
  delegate.on('click', 'button', handleButtonClicks);

  // Listen to all touch move
  // events that reach the body
  delegate.on('touchmove', handleTouchMove);

}, false);
```

A cool trick to handle images that fail to load:

```js
function handleImageFail() {
  this.style.display = 'none';
}

window.addEventListener('load', function() {
  var delegate = new Delegate(document.body);
  delegate.on('error', 'img', handleImageFail);
}, false);
```

Note: as of 0.1.2 you do not need to provide a DOM element at the point of instantiation, it can be set later via the `root` method.

Also note: as of 0.2.0 you cannot specify more than one `eventType` in a single call to `off` or `on`.

### Google Closure Compiler ###

Delegate supports compilation with `ADVANCED_OPTIMIZATIONS` ('advanced mode'), which should reduce its size by about 70% (60% gzipped). Note that exposure of the `Delegate` variable isn't forced therefore you must compile it along with all of your code.

## Tests ##

Tests are run using [buster](http://docs.busterjs.org/en/latest/) and sit in `test/`. To run the tests statically:

```
$ cd ftdomdelegate/
$ ./node_modules/.bin/buster-static -c test/buster.js
Starting server on http://localhost:8282/
```

...then point your browser to http://localhost:8282/.

```
$ ./node_modules/.bin/buster-server
buster-server running on http://localhost:1111
```

Point your browser to http://localhost:1111 and capture it, then in another terminal tab:

```
$ ./node_modules/.bin/buster-test -c test/buster.js
```

Code coverage is generated automatically with [istanbul](https://github.com/gotwarlost/istanbul).  The report outputs to `lcov-report/index.html`.

## API ##

### .on(eventType[, selector], handler[, useCapture]) ###

#### `eventType (string)` ####

The event to listen for e.g. `mousedown`, `mouseup`, `mouseout`, `error` or `click`.

#### `selector (string|function)` ####

Any kind of valid CSS selector supported by [`matchesSelector`](http://caniuse.com/matchesselector). Some selectors, like `#id` or `tag` will use optimized functions internally that check for straight matches between the ID or tag name of elements.

`null` is also accepted and will match the root element set by `root()`.  Passing a handler function into `.on`'s second argument is equivalent to `.on(eventType, null, handler)`.

#### `handler (function|boolean)` ####

Function that will handle the specified event on elements matching the given selector.  The function will receive two arguments: the native event object and the target element, in that order.

#### `useCapture (boolean)` ####

Whether or not to listen during the capturing (pass in `true`) or bubbling phase (pass in `false`).  If no value passed in, it will fallback to a 'sensible default', which is `true` for `error`, `blur` and `focus` events and `false` for all other types.

### .off([eventType][, selector][, handler][, useCapture]) ###

Calling `off` with no arguments will remove all registered listeners, effectively resetting the instance.

#### `eventType (string)` ####

Remove handlers for events matching this type considering the other parameters.

#### `selector (string|function)` ####

Only remove listeners registered with the given selector, among the other arguments.

If null passed listeners registered to the root element will be removed.  Passing in a function into `off`'s second parameter is equivalent to `.off(eventType, null, handler[, useCapture])` (the third parameter will be ignored).

#### `handler (function|boolean)` ####

Only remove listeners registered with the given handler function, among the other arguments.  If not provided, remove all handlers.

#### `useCapture (boolean)` ####

Only remove listeners with `useCapture` set to the value passed in.  If not provided, remove listeners added with `useCapture` set to `true` and `false`.

### .root([element]) ###

#### `element (Node)` ####

Set the delegate's root node.  If no element passed in the root node will be deleted and the event listeners will be removed.

### .destroy() ###

Short hand for off() and root(), ie both with no parameters. Used to reset the delegate object.

## Credits and collaboration ##

The developers of ftdomdelegate are [Matthew Andrews](https://twitter.com/andrewsmatt) and [Matthew Caruana Galizia](http://twitter.com/mcaruanagalizia). Test engineering by [Sam Giles](https://twitter.com/SamuelGiles_). The API is influenced by [jQuery Live](http://api.jquery.com/live/). All open source code released by FT Labs is licenced under the MIT licence. We welcome comments, feedback and suggestions. Please feel free to raise an issue or pull request.

repository: xcoderzach/swipe-grow

repo_name: xcoderzach/swipe-grow


text:
# Roles

This is the documentation for the Roles queries against the [RescueGroups.org](https://www.rescuegroups.org/) HTTP API v2.

[Full Documentation on RescueGroups.org](https://userguide.rescuegroups.org/display/APIDG/Object+definitions#Objectdefinitions-roles)

## Define
Performs roles.define query. This gives information about the API interface to your application. These are also used to build this SDK.

### Example Query

    $query = new \RescueGroups\Request\Objects\Roles\Define();

    $result = $api->executeRequest($query);
## GetList
Performs roles.list list query, typically suitable for filling HTML select fields.

### Example List Query

    $query = new \RescueGroups\Request\Objects\Roles\GetList();
    $result = $api->executeRequest($query);

repository: salernolabs/rescuegroups

gha_language: PHP

repo_name: salernolabs/rescuegroups


text:
# Professional Experience
## [Renesas Electronics Corporation](https://www.renesas.com/en-us/), Durham, NC, U.S.A. (2014 - Present)
### Applications Engineer (Micro-controllers)
*Assist customers in designing products with Renesas products.*
#### Achievements
* February 2016, Spot Award for Excellent Support.
* May 2016, President’s Award for Achievement in Sales

#### Technology Expertise
1. Universal Serial Bus (6 months)
	- Developed a strong understanding of USB peripheral operation for both Host and Device.
	- Port the USB-Host Shield firmware for the GR-SAKURA board. The GR-SAKURA board, based on the RX63N microcontroller, is the equivalent of Arduino in Asian markets.
	- Identify and debugged issues in the core of the USBX stack from third party vendor ExpressLogic provided for the Synergy Platform.
2. [Capacitive Touch Sensing](https://www.renesas.com/en-us/solutions/key-technology/human-interface/touch-sensor-system2.html) (2 years)
	- Gained a thorough understanding of the Capacitive Touch Sensing Unit peripheral for measuring small changes in capacitance.
	- Created two iterations of a Firmware Integration Technology compatible driver with thoroughly documented design, and test specifications.
	- Ported driver to the Synergy Platform.
	- Designed driver was delivered to large White Goods Manufacturers (W*******l, G*****l E******c, E********x).
3. Security for the Internet of Things (6 months)
	- Acquired a black-box understanding of the Secure Cryptography Engine.
	- Created an Application Note on using Salted-Challenge Response Authentication Mechanism using Secure Hashing Algorithm for Mutual Authentication.
4. Synergy Software Package
	- Acquired in-depth knowledge of the operation of SSP.
	-
5. Bluetooth Low Energy
	- Acquired in-depth operation knowledge of rBLE Host MCU stack for application design using microcontrollers.

#### Responsibilities
-	Provide system design reviews, development, testing, and bring up of new microcontroller board designs.
-	Provide technical support to customers creating electronic design with Renesas Products.
-	Apply knowledge of software in C, C++, C# and Python Programming for developing PC side tools.
-	Debug custom software deployed on Renesas products.
-	Create technical content and conduct technical courses, and practical training sessions at technical conferences, Renesas branches to train Field Application Engineers, Sales Representatives and customers.

## BNS Solutions, Walpole, MA, U.S.A. (2011 - 2014)
### Embedded Systems Engineer
*Design and develop real time, application-specific systems using 8, 16 or 32 bit Microcontrollers (MCUs).*

#### Technology Expertise
1. Porting Firmware
	- Ported firmware from an old legacy part approaching End Of Life to a new part.
	- Ported firmware from a FreeScale microcontroller to a Renesas Microcontroller.

2. Developing Application Firmware
	- Created firmware to demonstrate communication using Ethernet, CAN, and UART.
	- Created firmware to operate E-Ink Segmented Displays.
	- Created firmware for a low-power wireless (802.15.4) microcontroller application.
	- Created firmware to operate a three-phase Brushless DC motor with sensor feedback.

3. Board bring-up and testing
	- Learned to examine prototype boards received from contract manufacturers.
	- Testing of each functional unit to ensure proper operation of peripherals.

4. Simple Hardware Design and Review
	- Designed hardware for an Interface Panel communicating to a Fume-Hood controller (over Mod-bus).
	- Re-Spun Interface Panel to incorporate use of a Resistive Touch Screen Controller.
	- Sit-in on hardware design reviews and provide input.

#### Responsibilities
-	Contribute in developing application firmware in C/C++ for multiple projects in a variety of disciplines like medical monitoring, industrial equipment, food automation, communications, and motor control.
-   Developed supporting PC applications with C#, Processing or Python.
-	Provide system design reviews and assist in creating specifications for loosely defined products.
-	Responsible for proper bring up of prototype boards using understanding of schematics and layouts and correct use of lab test equipment. Writing verification and validation tests for mass production boards.

## Rajiv Gandhi Institute of Technology, Mumbai, MH, IN (2008 - 2009)
### Ad-hoc Lecturer
* Conducted theory and practical sessions for sophomore students in Engineering.*
#### Responsibilities
-   Conduct practical sessions
-	Conduct theory lecture on Industrial Electronics (full-semester).

# Presentations and Labs
## Renesas Devcon 2015, Anaheim, CA, U.S.A.
### Seminar
-	Capacitive Touch Sensing and Hardware based design using Renesas Microcontrollers
### Practical Session
- 	Capacitive Touch Interface design using Renesas Tools

## Renesas Devcon 2012, Anaheim, CA, U.S.A.
### Seminar
- Managing battery life for MCU based wireless systems using low power modes available with the 802.15.4 compatible Renesas R8C/3MQ microcontroller.
- Designing systems for driving EInk Segmented Displays using the RL78 microcontroller.

repository: rautonkar/website

repo_name: rautonkar/website


text:
safeldap - PHP LDAP validation library
========================================

The library contains three methods:
- ValidateInputForSafeLdapQuery
- CreateWhiteList
- Validate

Functions
---------

*CreateWhiteList*: - creates a custom regular expression based on any additional characters to be whitelisted for a particular call. The default selection is alphanumeric [a-zA-Z0-9]
Parameters:
- $whiteList - additional characters to be whitelisted

*Validate*: - actual validation of the input query against the regular expression
Parameters:
- $RegEx - regular expression to be used to validate
- $inputToValidate - input ldap query string to validate

*ValidateInputForSafeLdapQuery*: - Accepts ldap query string to validate for ldap insecure characters
The default validation is performed for alphanumeric characters only. Allows the caller to pass in additional characters that needs to be whitelisted for a particular query as needed.
Parameters:
- inputToValidate - the ldap parameter query to validate
- whiteList - additional characters to be whitelisted for a particular call

repository: gaurabb/validateldapqueryinphp

repo_name: gaurabb/validateldapqueryinphp


text:
# Dungeons and Dragons Companion Application

This Android application that runs different interfaces: Dungeon master and player. Each section has their own functions that they can perform.

Dungeon Master:
* List of all monsters
* List of all spells
* List of all items
* List of all equipment
* List of all feats
* Index of races
* Index of classes
* Rulebook
* Create homebrew content
* Pictures of locations

Players:
* Interactive character sheet
* Dice roller
* List of all feats
* Spellbook
* Owned equipment list

## Built With

* [Android Studio](https://developer.android.com/studio/) - The android application development platform
* [Google Cloud Firestore](https://firebase.google.com/) - The backend for databse
* [Github](https://github.com/) - Used to collaborate between authors

## Authors

* **Adrian LaCour**
* **Brad Dennis**
* **Damien Wiggins**
* **Trenton Blackburn**
* **Geoff Plasterr**

## License

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

gha_language: Java


text:
---
title:  "Workspace"
toc:  true
weight:  6
description: >
  Shared directory that all build steps begin at.
---

### Cloning

Vela automatically checks out the repository into a local volume that is mounted into each Docker container. This volume is generally referred to as a workspace, which defines the working directory shared by all steps in a build.

```sh
git clone https://github.com/octocat/hello-world.git <workspace>
```

### Working Directory

This ensures the code, dependencies, and compiled binaries are persisted and shared between the steps. The default workspace attached to every build is unique and matches the below pattern:

```sh
# Syntax
/home/<source org>/<source repo>

# Example
/home/octocat/hello-world
```

This would be the equivalent to the following Docker commands being executed:

```sh
docker volume create build-workspace

docker run --volume=build-workspace:/home/octocat/hello-world <image>
```


text:
---
title: "NCBImeta: efficient and comprehensive metadata retrieval from NCBI databases"
authors:
- admin
date: "2020-03-02"
doi: "10.21105/joss.01990"

# Schedule page publish date (NOT publication's date).
publishDate: "2020-06-04"

# Publication type.
# Legend: 0 = Uncategorized; 1 = Conference paper; 2 = Journal article;
# 3 = Preprint / Working Paper; 4 = Report; 5 = Book; 6 = Book section;
# 7 = Thesis; 8 = Patent
publication_types: ["2"]

# Publication name and optional abbreviated publication name.
publication: "The Journal of Open Source Software"
publication_short: "JOSS"

abstract: NCBImeta is a command-line application that downloads and organizes biological metadata from the National Centre for Biotechnology Information (NCBI). While the NCBI web portal provides an interface for searching and filtering molecular data, the output offers limited options for record retrieval and comparison on a much larger and broader scale. NCBImeta tackles this problem by creating a reformatted local database of NCBI metadata based on user search queries and customizable fields. The output of NCBImeta, optionally a SQLite database or text file(s), can then be used by computational biologists for applications such as record filtering, project discovery, sample interpretation, and meta-analyses of published work.

# Summary. An optional shortened abstract.
summary: NCBImeta is a command-line application that downloads and organizes biological metadata from the National Centre for Biotechnology Information (NCBI).

tags:
- Python
- Bioinformatics
- Genomics
- Metadata
- NCBI
- SRA
- Database
- NGS

featured: true

# links:
# - name: ""
#   url: ""
url_pdf: https://www.theoj.org/joss-papers/joss.01990/10.21105.joss.01990.pdf
url_code: 'https://github.com/ktmeaton/NCBImeta'
url_dataset: 'https://zenodo.org/record/3627329#.XtkEjkVKiUk'
url_poster: ''
url_project: 'https://ktmeaton.github.io/NCBImeta/'
url_slides: 'https://ktmeaton.github.io/slides/ncbimeta/ncbimeta_2019-09-16.pdf'
url_source: ''
url_video: ''

# Featured image
# To use, add an image named `featured.jpg/png` to your page's folder.
# image:
#  caption: 'Image credit: [**Unsplash**](https://unsplash.com/photos/jdD8gXaTZsc)'
#  focal_point: ""
#  preview_only: false

# Associated Projects (optional).
#   Associate this publication with one or more of your projects.
#   Simply enter your project's folder or file name without extension.
#   E.g. `internal-project` references `content/project/internal-project/index.md`.
#   Otherwise, set `projects: []`.
projects: [content/project/ncbimeta/]

# Slides (optional).
#   Associate this publication with Markdown slides.
#   Simply enter your slide deck's filename without extension.
#   E.g. `slides: "example"` references `content/slides/example/index.md`.
#   Otherwise, set `slides: ""`.
# slides: ncbimeta
---

repository: NicolasGasnier/academic-kickstart

repo_name: NicolasGasnier/academic-kickstart


text:
[![npm](https://img.shields.io/npm/v/capsize.svg?style=for-the-badge)](https://www.npmjs.com/package/capsize)

> Capsize makes the sizing and layout of text as predictable as every other element on the screen.
>
> Using font metadata, text can now be sized according to the height of its capital letters while trimming the space above capital letters and below the baseline.

```bash
$ npm i --save capsize
```

```js
import capsize from 'capsize';

const styles = capsize({
  capHeight: 16,
  lineGap: 8,
  fontMetrics: {
    capHeight: 700,
    ascent: 1058,
    descent: -291,
    lineGap: 0,
    unitsPerEm: 1000,
  },
});
```

# Options

## Text size

Capsize supports two methods of defining the size of text, `capHeight` and `fontSize`.

**NOTE: You should only ever pass one or the other, not both.**

### `capHeight: <number>`

Sets the height of the capital letters to the defined value. Defining typography in this way makes aligning to a grid or with other elements, e.g. icons, a breeze.

### `fontSize: <number>`

Setting the font size allows you to get all the benefits of the white space trimming, while still specifying an explicit `font-size` for your text. This can be useful when needed to match a concrete design spec or fitting into an existing product.

## Line height

Capsize supports two mental models for specifying line height, `lineGap` and `leading`. If you pass neither the text will follow the default spacing of the specified font, e.g. `line-height: normal`.

**NOTE: You should only ever pass one or the other, not both.**

### `lineGap: <number>`

Sets the number of pixels between lines, as measured between the baseline and cap height of the next line.

### `leading: <number>`

Sets the line height to the provided value as measured from the baseline of the text. This aligns the web with how typography is treated in design tools.

## Font Metrics

This metadata is extracted from the metrics tables inside the font itself. You can use [the Capsize website](https://seek-oss.github.io/capsize/) to find these by selecting a font and referencing `JavaScript` tab in step 3.

# Utilities

### getCapHeight

Returns the actual rendered cap height for a specific font size given the provided font metrics.

```ts
import { getCapHeight } from 'capsize';

const actualCapHeight = getCapHeight({
  fontSize: 24,
  fontMetrics: {
    ...
  }
})
```

# License

MIT.

repository: daviavmello/portfolio

repo_name: daviavmello/portfolio


text:
ifttt-webhook
=============

A webhook middleware for the ifttt.com service forked from <https://github.com/captn3m0/ifttt-webhook>
Please read the documention there to understand how this is working.

## Changes in this fork

The following information is passed along by the webhook
in the raw body of the post request in json encoded format.

```json
    {
  "user" : "username specified in ifttt",
  "password" : "password specified in ifttt",
  "data" : "description specified in ifttt",
    }
```

In Categories the target is specified. The target base url is specified in
the Application configuration. The first given categorie is appended as
target.

  base_url/categorie

#Limitations
Only categories matching [A-Z][a-z][0-9]+ are accepted.
Currently only the first categorie is used.

#Use
Clone the git repo to some place, setup your webserver and use that as the
wordpress installation location in ifttt.com channel settings.

# Planning

  * Sending more than one webhook request
  * Allow full urls in categories (seems that IFTTT passes them untouched)

repository: hboers/ifttt-webhook

repo_name: hboers/ifttt-webhook


text:
# subber
[![Build Status](https://travis-ci.org/Kuxe/subber.svg?branch=master)](https://travis-ci.org/Kuxe/subber)
[![Build Status](https://ci.appveyor.com/api/projects/status/github/kuxe/subber?svg=true)](https://ci.appveyor.com/project/Kuxe/subber)

[subber.hpp](https://github.com/Kuxe/subber/blob/master/subber.hpp) contains a C++14 implementation of the publisher-subscriber pattern. The purpose of subber is simplicity. This is illustrated by the following self-contained sample code:

```c++
#include "subber.hpp"

struct SimpleEvent { };

struct Foo : public Subber<SimpleEvent> {
	void notified(const SimpleEvent& event) override {
		printf("Foo received SimpleEvent\n");
	}
};

int main(int argc, char** argv) {
	SimpleEvent simpleEvent;
	Foo foo;
	publish(simpleEvent); //"Foo recieved SimpleEvent" is printed
	return 0;
}
```

It is not uncommon that a class should listen to several events. Any class can have multiple subbers (=listen to several events) as shown in the following example:

```c++
#include "subber.hpp"

struct SimpleEvent { };
struct OtherEvent { };
struct Foo : public Subber<SimpleEvent, OtherEvent> {
	void notified(const SimpleEvent& event) override { /* do something */ }
	void notified(const OtherEvent& event) override { /* do some other thing */ }
};

int main(int argc, char** argv) {
	SimpleEvent simpleEvent;
	OtherEvent otherEvent;
	Foo foo;
	publish(simpleEvent, otherEvent); //Something is done and some other thing is done
	return 0;
}
```
Note that you can publish several events at once!

Subber does not guarantee any call-order of notified.

A more rigorous example can be found in [example.cpp](https://github.com/Kuxe/subber/blob/master/example.cpp).

subber compiles on g++ 6.1.1 using the --std=c++14 flag.

Happy coding :+1:!

repository: Kuxe/subber

repo_name: Kuxe/subber


text:
# KArmBandit
### **\<<Reinforcement Learning\>> Chapter 3**
I'm reading \<<Reinforcement leraning\>> right now.  This program is made for learning porpuse.

## Install and run
### MacOS
**Make**
```make```

Make sure you have ```Logs``` directory in the same folder.  If not, execute
```mkdir Logs```

**Run**
```./karms --help```

--plot option plots the average rewards of each agent.
--sigma sets the sigma of the normal distribution.

You may also run python script separatly to plot the sattstic.
```python plot_stats.py```

### Other platform
N/A.  Well welcome to conrtibute your own make file or solution file!  :)

## How to make your own agent?
Implement an Agent derived from AgentInterface and implement the **int PullArm()** function, that's it!  You have made an agent now.

I have created a simple agent RandomAgent, let's see how it looks:
```
/* Implements a random agent. */
#include <random>
#include "AgentInterface.h"

template<typename T>
class RandomAgent: public AgentInterface<T>{
    private:
    public:
        RandomAgent(std::string &&name): AgentInterface<T>(std::forward<std::string&&>(name)) {
        }

        int PullArm() override {
            // Do some logic and return selection.  Let's return a random selection.
            int selection = this->gen() % (AgentInterface<T>::testbed->GetArmsCount());

            // Operate testbed and pull arm.
            double reward = AgentInterface<T>::testbed->PullArm( this, selection );

            return selection;
        }
};
```
You can access Testbed class from an Agent.   You may take a look into Testbed.h to see what functions you could access.  There are just few public function in that class.

## Structure of the program
We have
- AgentInterface
- Testbed
- MachineInterface

Testbed provides a testbed to test and run all the agents you have made.  It has a K Armed Mahine inside itself.  Bascially it will use the agents to pull the machine repeatedly and record how it performs.

The machine is a K Armed Machine.  It defines how many arms in there, and what's the yiedl function of each arm.
The true value q∗(a) of each of the ten actions was selected according to a normal distribution with mean zero and unit variance, and then the actual rewards were selected according to a mean q∗(a) unit variance normal distribution

The Agent makes decision on which arm to pull.  You may consider to implement your own algorithm for this process.

## Benchmarks

```
./karms --plot --tournament_times 800 --k 10 --sigma 2.5
--help to display help infomation.
--plot to plot the statistic after running tests.
--sigma X to set normal distribution's sigma.  This parameter only works when mahcine uses Normal distribution
--pulltimes X to set test pulling times.
--tournament_times to set how many tournament will be runned.
--k K K arms.
sigma 2.5
Running tournment 800 times
 ------------------------------------------------------------------------------------
|                          Name                          |    1st    |    2nd    |3rd|
 ------------------------------------------------------------------------------------
|                      My UCB agent                      |    349    |    316    |122|
 ------------------------------------------------------------------------------------
|               WL's sample average agent                |    261    |    283    |183|
 ------------------------------------------------------------------------------------
|               WL's Gradient Bandit Agent               |    186    |    156    |205|
 ------------------------------------------------------------------------------------
|         WL's sample average agent with epslion         |     4     |     45    |290|
 ------------------------------------------------------------------------------------
Pulling 1000 Times
 ------------------------------------------------------------------------------------
|Rank |                  Agent Name                 |  Total Score  |  Average Score |
 ------------------------------------------------------------------------------------
|  1  |          WL's Gradient Bandit Agent         |  8405.147187  |    8.405147    |
 ------------------------------------------------------------------------------------
|  2  |                 My UCB agent                |  8251.539018  |    8.251539    |
 ------------------------------------------------------------------------------------
|  3  |          WL's sample average agent          |  8151.471226  |    8.151471    |
 ------------------------------------------------------------------------------------
|  4  |    WL's sample average agent with epslion   |  8042.607480  |    8.042607    |
 ------------------------------------------------------------------------------------
```

![alt text](https://github.com/wenlianglaw/KArmBandit/blob/master/Images/Sigma_1.0_1.png "benchmark_fig_sigma_1.0")

![alt text](https://github.com/wenlianglaw/KArmBandit/blob/master/Images/Sigma_2.5_1.png "benchmark_fig_sigma_2.5_1")

repository: wenlianglaw/KArmedBandit

repo_name: wenlianglaw/KArmedBandit


text:
# multimodal-transport-nodes
Generates a list of locations that are likely to be start/stop nodes in a multimodal transport scheme

Data is based on [OpenStreetMaps](OpenStreetMaps.org) and [Geonames](Geonames.org).

Please check their websites for usage and licensing rules.

Prerequisits:

 The scripts are made to run on linux systems.

 You need some required packages that can be installed on ubuntu with the following command:

    sudo apt-get install wget build-essential zlib1g-dev

Now you can execute the script for a country of your choice.

It will:
 1. Download raw OSM and Geonames files
 2. Download required osm tools and build them (osmfilter and osmconvert)
 3. Convert and filter the raw source files
 4. Clean everything up
 5. Leave you with tab separated text files for further usage

The files contain at least geocoordinates and names for:
  1. RailStations
  2. RailStops
  3. BusStops
  4. Addresses (without Numbers)
  5. Streets
  6. Towns

Example usage:

    git clone https://github.com/forgemo/multimodal-transport-nodes.git
    cd multimodal-transport-nodes
    chmod +x germany.sh
    ./germany.sh

The result will be a "mmtn-germany" folder with the generated files.

Todo:
 - more countries
 - resulting files should become one "merged" file

repository: forgemo/multimodal-transport-nodes

repo_name: forgemo/multimodal-transport-nodes


text:
---
title: Manipulate
---

Once you have a `Moment`, you may want to manipulate it in some way. There are a number of methods to help with this.

Moment.js uses the [fluent interface pattern](https://en.wikipedia.org/wiki/Fluent_interface), also known as [method chaining](https://en.wikipedia.org/wiki/Method_chaining). This allows you to do crazy things like the following.

```javascript
moment().add(7, 'days').subtract(1, 'months').year(2009).hours(0).minutes(0).seconds(0);
```

**Note:** It should be noted that moments are mutable. Calling any of the manipulation methods will change the original moment.

If you want to create a copy and manipulate it, you should use `moment#clone` before manipulating the moment. [More info on cloning.](#/parsing/moment-clone/)


text:
# Lecidea tornoënsis Nyl. SPECIES

#### Status
SYNONYM

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

#### Published in
Herb. Mus. Fenn. 110 (1859)

#### Original name
Lecidea tornoënsis Nyl.

### Remarks
null

repository: mdoering/backbone

path: /life/Fungi/Ascomycota/Lecanoromycetes/Lecanorales/Ramalinaceae/Japewia/Japewia tornoënsis/ Syn. Lecidea tornoënsis/README.md

repo_name: mdoering/backbone


text:
---
title: "New Banksy Mural in New York Protests Turkish Artist’s Imprisonment"
description: "Banksy's 70-foot-long mural was unveiled on Thursday,protesting the imprisonment of the Turkish-Kurdish artist and journalist Zehra Dogan, who was sentenced last March for painting the destruction of a Kurdish town, with Turkey’s flag flying over rubble"
---

Great article on one artist supporting the work of another.

[New York Times](https://www.nytimes.com/2018/03/15/arts/design/banksy-mural-new-york-zehra-dogan.html)

url: https://raw.githubusercontent.com/biancaflores96/web1-sp/0c2956e5d22a4350f0f884e8bfed7b8d38950411/_posts/2018-03-16-Banksy Mural in New York.markdown

extension: markdown


text:
---
id: utilities
title: Utilities
sidebar_label: Utilities
---

## `Edge<State>`

### Edge helps compare if state was updated without Equatable

In a single state tree, comparing for reducing the number of updates would be most important for keep performance. However, implementing Equatable is not easy basically. Instead, adding a like flag that indicates updated itself, it would be easy

### Actually, we need to get to flag that means different, it no need to be equal

Actually, we need to get to flag that means **different**, it no need to be **equal**.

### Edge does embed state with versioning

`Edge` manages the version of itself, the version will increment each modification. however, it can't get how exactly modified from the modification. and Edge returns equality by comparing their version.
That is the reason why Edge may return boolean that false positive.
If Edge returns equality false, it may be actually equals.

```swift
struct YourState {
  var name: String = ...
}

struct AppState: Equatable {

  @Edge var yourState YourState = .init()
}
```

:::tip
Since `Edge` enables the state to be `Equatable`, a root state can be Equatable with synthesizing.
If you're struggling with supporting Equatable, try to use `Edge` with that.
:::

```
appState.yourState.name

// get unique value that indicates updated to compare with previous value.
// this value would be updated on every mutation of this tree.
appState.$yourState.version
```

### Edge can validate the value and modify to be correctly

Edge supports a concept of middleware that catch a new value and modifiable.
Please check `Edge.Middleware` to see more detail.

```swift
let middleware = Edge<Value>.Middleware.init(onSet: { value in /* do something */ })
```

To set it up, we can declare as followings:

```swift
@Edge(middleware: .assert { $0 >= 0 }) var count = 0
```

It can be combined from multiple middleware.

```swift
@Edge(middleware: .init([
  .assert { $0 >= 0 },
  .init { value in /* performs something */ },
]))
var count = 0
```

## assign - assignee

In specific cases, it needs to projects value from others into the Store.

- Having multiple stores and needs to be integrated with each other.
- Having other reactive streams and needs to be stored the value in the Store

In these cases, `assign` and `assignee` operators help.

Assigns the value from other Store's state to Store's state.

```swift
let store1 = Store()
let store2 = Store()

store1
  .derived(.map(\.count))
  .assign(to: store2.assignee(\.count))
```

Assigns the value from the Publisher to Store's state.

```swift
let publisher: Combine.Publisher<Int>
let store2 = Store()

publisher
  .assign(to: store2.assignee(\.count))
```

repository: subdiox/Verge

repo_name: subdiox/Verge


text:
# Working with twarc data

After you have your jsonl file from from a twarc search, clone this repository to your local machine. In terminal/console wherever you want the 751-Fall20 folder to be located:

`git clone [paste the url your copied from the code button above]`

Put the twarc jsonl file you downloaded into the main 751-Fall20 folder on your computer.

To make it into a CVS file you can import into Google Sheets:

`./utils/json2csv.py your-file-name.jsonl > your-file-name.csv`

To make it into a Gephi file you can do network analysis with:

`./network.py your-file-name.jsonl your-file-name.gexf --users`

Gephi tutorial (there are many, but here is one): https://www.youtube.com/watch?v=2FqM4gKeNO4


text:
# Decision on how to convert from Ebix to CIM standards

* Status: [Accepted] <!-- optional -->
* Deciders: Martin F. Hansen, René Thyge Nielsen, Daniel Bjerring Jørgensen, Søren Søndergaard <!-- optional -->
* Date: 2021-03-18 (PI4 Planning event) <!-- optional -->

Technical Story: <https://github.com/Energinet-DataHub/geh/issues/6>

## Context and Problem Statement

The Danish electricty market are communicating with the Datahub using a Ebix formated message content for both incoming and outgoing messages. The decision for the Datahub 3.0 is that all internal communication are done in a CIM (ENTSO-e format) formatting. To be able to implement CIM conversion it has been decided that the system team will provide a 'CIM dictionary' for following RSM-messages (EbiX) 001, 004, 033, a conversion-engine and a guide for how all teams are able to implement the conversion engine and create CIM aligned data within their repective domains.

## Decision Drivers

* Driver 1: Responsibility for the dictionary of EbiX-CIM needs to be centralized as changes to formats comes from the business side, and one entry point is necessary to maintain an aligned format across the system.
* Driver 2: We do not wish to create a bottleneck for the flows by creating one common conversion for all domains/business processes.
* Driver 3: We are able to create one converter, that all teams can implement within the host layer of each domain - containing all relevant data for the domain.
* Driver 4: We would like for the domains to be able to create their internal DTO's based on needed data - but still aligned with CIM naming.

## Considered Options

* 1. It was considered to deliver one conversion tool within message entry point of the system (API management)
* 2. It was considered that each domain had the freedom to do their own conversion to CIM or internal format by using a centralized aligned 'dictionary' and tool created for this.
* 3. It was considered that the system team would implement all conversion tools in domain across the platform

## Decision Outcome

Chosen option: "[option 2]", because it is the option that would support all decision drivers, giving an aligned naming according to ENTSO-e standard, ensure team responsibility but on an aligned format for internal implementation within domains.

### Positive Consequences

* No bottleneck created in API management
* One entry point of changes to naming and formats from the business
* One tool, that can be used in all domains
* Possible for each domain to create internal DTO's

url: https://raw.githubusercontent.com/johnddonnelly/green-energy-hub-1/e6e8b752c399a418c39e44ce425744f5c9f75a59/docs/architecture-decision-record/ADR-0002 Decision on how to convert from Ebix to CIM standards.MD


text:
##### __tostring
returns the complete data array:
```php
print_r($config); // Array
```
(Note: This is redundant. You can either call `$config->get()` or just `$config`, same effect. I find it to be not very self-documenting, but who am I to tell you how to code.)

repository: Radiergummi/libconfig

repo_name: Radiergummi/libconfig


text:
Easy and Fast internationalization for your Flutter Apps

![Pub Version](https://img.shields.io/pub/v/easy_localization?style=flat-square)
![Code Climate issues](https://img.shields.io/github/issues/aissat/easy_localization?style=flat-square)
![GitHub closed issues](https://img.shields.io/github/issues-closed/aissat/easy_localization?style=flat-square)
![GitHub contributors](https://img.shields.io/github/contributors/aissat/easy_localization?style=flat-square)
![GitHub repo size](https://img.shields.io/github/repo-size/aissat/easy_localization?style=flat-square)
![GitHub forks](https://img.shields.io/github/forks/aissat/easy_localization?style=flat-square)
![GitHub stars](https://img.shields.io/github/stars/aissat/easy_localization?style=flat-square)
![Coveralls github branch](https://img.shields.io/coveralls/github/aissat/easy_localization/dev?style=flat-square)
![GitHub Workflow Status](https://img.shields.io/github/workflow/status/aissat/easy_localization/Flutter%20Tester?longCache=true&style=flat-square&logo=github)
![CodeFactor Grade](https://img.shields.io/codefactor/grade/github/aissat/easy_localization?style=flat-square)
![GitHub license](https://img.shields.io/github/license/aissat/easy_localization?style=flat-square)
![Sponsors](https://img.shields.io/opencollective/all/flutter_easy_localization?style=flat-square)
![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)

## Why easy_localization?

- 🚀 Easy translations for many languages
- 🔌 Load translations as JSON, CSV, Yaml, Xml using [Easy Localization Loader](https://github.com/aissat/easy_localization_loader)
- 💾 React and persist to locale changes
- ⚡ Supports plural, gender, nesting, RTL locales and more
- ⁉ Error widget for missing translations
- ❤ Extension methods on `Text` and `BuildContext`
- 💻 Code generation for localization files and keys.
- 👍 Uses BLoC pattern

## Getting Started

### 🔩 Installation

Add to your `pubspec.yaml`:

```yaml
dependencies:
  easy_localization: <last_version>
```

Create folder and add translation files like this

```
assets
└── translations
    ├── {languageCode}.{ext}                  //only language code
    └── {languageCode}-{countryCode}.{ext}    //or full locale code
```

Example:

```
assets
└── translations
    ├── en.json
    └── en-US.json
```

Declare your assets localization directory in `pubspec.yaml`:

```yaml
flutter:
  assets:
    - assets/translations/
```

### 🔌 Loading translations from other resources

You can use JSON,CSV,HTTP,XML,Yaml files, etc.

See [Easy Localization Loader](https://github.com/aissat/easy_localization_loader) for more info.

### ⚠ Note on **iOS**

For translation to work on **iOS** you need to add supported locales to
`ios/Runner/Info.plist` as described [here](https://flutter.dev/docs/development/accessibility-and-localization/internationalization#specifying-supportedlocales).

Example:

```xml
<key>CFBundleLocalizations</key>
<array>
	<string>en</string>
	<string>nb</string>
</array>
```

### ⚙ Configuration app

Add EasyLocalization widget like in example

```dart
import 'package:flutter/material.dart';
import 'package:flutter_localizations/flutter_localizations.dart';
import 'package:easy_localization/easy_localization.dart';

void main() {
  runApp(
    EasyLocalization(
      supportedLocales: [Locale('en', 'US'), Locale('de', 'DE')],
      path: 'assets/translations', // <-- change patch to your
      fallbackLocale: Locale('en', 'US'),
      child: MyApp()
    ),
  );
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      localizationsDelegates: context.localizationDelegates,
      supportedLocales: context.supportedLocales,
      locale: context.locale,
      home: MyHomePage()
    );
  }
}
```

[**Full example**](https://github.com/aissat/easy_localization/blob/master/example/lib/main.dart)

### 📜 Easy localization widget properties

| Properties       | Required | Default                   | Description |
| ---------------- | -------- | ------------------------- | ----------- |
| key              | false    |                           | Widget key. |
| child            | true     |                           | Place for your main page widget. |
| supportedLocales | true     |                           | List of supported locales. |
| path             | true     |                           | Path to your folder with localization files. |
| assetLoader      | false    | `RootBundleAssetLoader()` | Class loader for localization files. You can use custom loaders from [Easy Localization Loader](https://github.com/aissat/easy_localization_loader) or create your own class. |
| fallbackLocale   | false    |                           | Returns the locale when the locale is not in the list `supportedLocales`.|
| startLocale      | false    |                           | Overrides device locale. |
| saveLocale       | false    | `true`                    | Save locale in device storage. |
| useOnlyLangCode  | false    | `false`                   | Trigger for using only language code for reading localization files.

Example:
`en.json //useOnlyLangCode: true`
`en-US.json //useOnlyLangCode: false`  |
| preloaderColor   | false    | `Colors.white`            | Background color for EmptyPreloaderWidget.
If you use a different color background, change the color to avoid flickering |
| preloaderWidget  | false    | `EmptyPreloaderWidget()`  | Shows your custom widget while translation is loading. |

## Usage

### 🔥 Change or get locale

Easy localization uses extension methods [BuildContext] for access to locale.

It's more easiest way change locale or get parameters 😉.

ℹ No breaking changes, you can use old the static method `EasyLocalization.of(context)`

Example:

```dart
context.locale = Locale('en', 'US');

print(context.locale.toString());
```

### 🔥 Translate `tr()`

Main function for translate your language keys

You can use extension methods of [String] or [Text] widget, you can also use `tr()` as a static function.

```dart
Text('title').tr() //Text widget

print('title'.tr()); //String

var title = tr('title') //Static function
```

#### Arguments:

| Name | Type | Description |
| -------- | -------- | -------- |
| context| `BuildContext` | The location in the tree where this widget builds |
| args| `List<String>` | List of localized strings. Replaces `{}` left to right |
| namedArgs| `Map<String, String>` | Map of localized strings. Replaces the name keys `{key_name}` according to its name |
| gender | `String` | Gender switcher. Changes the localized string based on gender string |

Example:

``` json
{
   "msg":"{} are written in the {} language",
   "msg_named":"Easy localization are written in the {lang} language",
   "msg_mixed":"{} are written in the {lang} language",
   "gender":{
      "male":"Hi man ;) {}",
      "female":"Hello girl :) {}",
      "other":"Hello {}"
   }
}
```

```dart
// args
Text('msg').tr(args: ['Easy localization', 'Dart']),

// namedArgs
Text('msg_named').tr(namedArgs: {'lang': 'Dart'}),

// args and namedArgs
Text('msg_mixed').tr(args: ['Easy localization'], namedArgs: {'lang': 'Dart'}),

// gender
Text('gender').tr(gender: _gender ? "female" : "male"),

```

### 🔥 Plurals `plural()`

You can translate with pluralization.
To insert a number in the translated string, use `{}`. Number formatting supported, for more information read [NumberFormat](https://pub.dev/documentation/intl/latest/intl/NumberFormat-class.html) class documentation.

You can use extension methods of [String] or [Text] widget, you can also use `plural()` as a static function.

#### Arguments:

| Name | Type | Description |
| -------- | -------- | -------- |
| context| `BuildContext` | The location in the tree where this widget builds|
| value| `num` | Number value for pluralization |
| format| `NumberFormat` | Formats a numeric value using a [NumberFormat](https://pub.dev/documentation/intl/latest/intl/NumberFormat-class.html) class |

Example:

``` json
{
  "day": {
    "zero":"{} дней",
    "one": "{} день",
    "two": "{} дня",
    "few": "{} дня",
    "many": "{} дней",
    "other": "{} дней"
  },
  "money": {
    "zero": "You not have money",
    "one": "You have {} dollar",
    "many": "You have {} dollars",
    "other": "You have {} dollars"
  }
}
```
⚠ Key "other" required!

```dart
//Text widget with format
Text('money').plural(1000000, format: NumberFormat.compact(locale: context.locale.toString())) // output: You have 1M dollars

//String
print('day'.plural(21)); // output: 21 день

//Static function
var money = plural('money', 10.23) // output: You have 10.23 dollars
```

### 🔥 Delete save locale `deleteSaveLocale()`

Clears a saved locale from device storage

Example:

```dart
RaisedButton(
  onPressed: (){
    context.deleteSaveLocale();
  },
  child: Text(LocaleKeys.reset_locale).tr(),
)
```

### 🔥 Get Easy localization widget properties

At any time, you can take the main [properties](#-easy-localization-widget-properties) of the Easy localization widget using [BuildContext].

Are supported: supportedLocales, fallbackLocale, localizationDelegates.

Example:

```dart
print(context.supportedLocales); // output: [en_US, ar_DZ, de_DE, ru_RU]

print(context.fallbackLocale); // output: en_US
```

## 💻 Code generation

Code generation supports only json files, for more information run in terminal `flutter pub run easy_localization:generate -h`

### Command line arguments

| Arguments | Short |  Default | Description |
| ------ | ------ |  ------ | ------ |
| --help | -h |  | Help info |
| --source-dir | -S | resources/langs | Folder containing localization files |
| --source-file | -s | First file | File to use for localization |
| --output-dir | -O | lib/generated | Output folder stores for the generated file |
| --output-file | -o | codegen_loader.g.dart | Output file name |
| --format | -f | json | Support json or keys formats |

### 🔌 Localization asset loader class

Steps:
1. Open your terminal in the folder's path containing your project
2. Run in terminal `flutter pub run easy_localization:generate`
3. Change asset loader and past import.

```dart
import 'generated/codegen_loader.g.dart';
...
void main(){
  runApp(EasyLocalization(
    child: MyApp(),
    supportedLocales: [Locale('en', 'US'), Locale('ar', 'DZ')],
    path: 'resources/langs',
    assetLoader: CodegenLoader()
  ));
}
...
```
4. All done!

### 🔑 Localization keys

If you have many localization keys and are confused, key generation will help you. The code editor will automatically prompt keys

Steps:
1. Open your terminal in the folder's path containing your project
2. Run in terminal `flutter pub run easy_localization:generate -f keys -o locale_keys.g.dart`
3. Past import.

```dart
import 'generated/locale_keys.g.dart';
```
4. All done!

How to usage generated keys:

```dart
print(LocaleKeys.title.tr()); //String
//or
Text(LocaleKeys.title).tr(); //Widget
```

## Screenshots

| Arabic RTL | English LTR | Error widget |
| ---------- | ----------- | ------------ |
| ![Arabic RTL](https://raw.githubusercontent.com/aissat/easy_localization/master/screenshots/Screenshot_ar.png "Arabic RTL") | ![English LTR](https://raw.githubusercontent.com/aissat/easy_localization/master/screenshots/Screenshot_en.png "English LTR") | ![Error widget](https://raw.githubusercontent.com/aissat/easy_localization/master/screenshots/Screenshot_err.png "Error widget") |

## Donations

We need your support. Projects like this can not be successful without support from the community. If you find this project useful, and would like to support further development and ongoing maintenance, please consider donating.

### Sponsors

### Contributors thanks

![contributors](https://contributors-img.firebaseapp.com/image?repo=aissat/easy_localization)

branch_name: refs/heads/develop


text:
# Writing an Ansible module in PHP

## Use case

Primarily the issue has been that most CLI apps that help to deploy applications can give little insight into what has actually changed. Sometimes it is possible to use `changed_when` and inspect stderr/stdout, but most of the time it is not possible to tell reliably from just that. This is the same with helper CLI applications for websites like Drush and WP-CLI.

## Getting started with Composer

Use the standard `composer require` command:

```bash
composer require appdynamics/ansible-php:dev-develop
```

## Boilerplate

Unfortunately there is not much of a way to get around Ansible's limitations with other languages besides Python. And there probably will never be. Therefore, you need to have this boilerplate at the top of your module:

```php
#!/usr/bin/env php
<?php
function _require_ansible_php() {
    global $argv;
    $argFile = $argv[count($argv) - 1];
    $args = preg_split('/\s+/', file_get_contents($argFile), null, PREG_SPLIT_NO_EMPTY);
    foreach ($args as $i => $arg) {
        list($key, $val) = preg_split('/=/', $arg, 2);
        if ($key === 'ansible_php') {
            require_once $val . '/vendor/autoload.php';
            return true;
        }
    }
    return false;
}
if (!_require_ansible_php() || !class_exists('AnsiblePhp\AnsibleModule')) {
    print json_encode(array('failed' => true, 'msg' => 'Failed to find AnsiblePhp library'));
    exit(1);
}
use AnsiblePhp\AnsibleModule;
```

## Example module

Here we are writing a very basic module to hook into WordPress and update an option idempotently (to not make any change if the option is already set to the value requested).

The task will look like this:

```yaml
# Variable exists like this in YAML:
# some_key_value: {dict_key: 'value'}

- name: 'Set some_key to [dict_key => value]'
  wordpress: ansible_php=/where-i-will-deploy-ansible-php
             working_dir=/srv/www
             option=some_key
             value={{some_key_value|to_json}}
```

Very important:

* You must *always* pass the `ansible_php` key and it must be a path where this source code lives. This can be any code base that is using Composer and has this Ansible PHP added as a dependency.
* Always use the `to_json` filter for non-scalar values.

```php
// Boilerplate goes here

function main() {
    $module = new AnsibleModule([
        'working_dir' => ['type' => 'directory', 'required' => true],
        'option' => [],
        'value' => [],
    ]);
    $changed = false;
    $data = [];

    // Get WordPress bootstrap include in (wp-config.php)
    $wpDir = realpath($module->params['working_dir']);
    define('ABSPATH', $wpDir.'/'); // Note the ending /
    $config = sprintf('%s/wp-config.php', $wpDir);
    require $config;

    // Idempotently update an option
    // Note that keys specified in the argument spec (the argument to AnsibleModule) are always existant but if not specified they are null
    // If a key is not specified by the task but has a default value, the key will have that value
    if ($module->params['option']) {
        if (!isset($module->params['value'])) {
            // You must *always* pass at least the msg key to #failJson()
            $module->failJson(['msg' => 'Value ("value" key) must be set when using option']);
        }

        $value = $module->params['value'];

        // We may want to only decode from JSON if we can see a complex type
        if ($value[0] == '{' || $value[0] == '[') {
            $value = $module->decodeJson($value); // #decodeJson checks for errors and will throw an exception
        }

        // Do not use null or anything non-random because null can be in the database just as easily
        $randomValue = md5(wp_rand().time());
        $current = get_option($module->params['option'], $randomValue);

        if ($current != $value || $current == $randomValue) {
            $changed = true;
            update_option($module->params['option'], $value);
        }
        else {
            $value = $current;
        }

        $data['option'] = [$module->params['option'] => $value];
    }

    // Exit correctly, and do not allow above code to change the 'changed' key
    $module->exitJson(array_merge($value, [
        'changed' => $changed,
    ]);
}

main();
```

This file lives in your Ansible playbook's `library` directory or a path you specify for modules in your Ansible configuration or command line. In this case it is named exactly `wordpress`.

## Notes

* There is an error handler and exception handler that will always act like `fail_json` and print out the exception or error message and a backtrace.
* Be careful when including 3rd party code and be sure to set up `php.ini` to your liking. On a production end-point you may want all errors off except for logging, even for CLI.
* WordPress plugins are of varying quality and may trigger warnings that will trigger exceptions in your module that may not appear on the site due to PHP settings and WordPress' very relaxed error handler by default. This can be similar (but less so) for Drupal.
* Regardless of framework, if your own site's code (that you wrote) is triggering errors in your Ansible module you should probably fix that code and preferably *not* send me an issue or pull request for some strange use case.

### Example error output (`#failJson`)

Note that it will not be prettified from Ansible (this is from `ansible-playbook -v`).

```json
{
    "msg": "Argument \"random\" is invalid",
    "line": 72,
    "bt": [{
        "file": "\/some-place\/test.php",
        "line": 22,
        "function": "__construct",
        "class": "AnsiblePhp\\AnsibleModule",
        "type": "->",
        "args": [{
            "dir": []
        }]
    }],
    "failed": true
}
```

## Locally testing

Instead of using `ansible` you can do something like the following:

```bash
# Set up a new project that has Ansible PHP
mkdir bin
curl -sS https://getcomposer.org/installer | php -- --install-dir=bin
php bin/composer.phar require appdynamics/ansible-php:dev-develop

# Create the argument file (just like Ansible does). Note the argument ansible_php
echo 'ansible_php=. working_dir=/something-real key=something value={"dict_key": "value"}' > args

# Run
php mymodule args ; echo
```

There is an `echo` here only because no newline is printed after the JSON output (which is on purpose).

# Deploying Ansible PHP alone

Before you can use Ansible-PHP in your own module, you need to send this library to the machine and then configure it with Composer. These are the tasks:

```yaml
- name: 'Install Composer'
  shell: curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/bin --filename=composer
         creates=/usr/bin/composer

- name: 'Install ansible-php'
  git: repo=git://github.com/Appdynamics/ansible-php
       dest=/opt/www/ansible-php
  register: ansible_php_git

- name: 'Set up ansible-php'
  composer: working_dir=/opt/www/ansible-php
  when: ansible_php_git.changed
```

Note: This is to install a barebones version of Ansible-PHP. You may want to consider using `composer require appdynamics/ansible-php:dev-develop` and building your own project so that you can handle all dependencies properly. You can also add Ansible PHP to any existing code base already using Composer and use that path (with `/vendor/ansible-php`) for where Ansible PHP lives.

# Contributing

* PSR standards
* Make a fork, a feature branch off the `develop` branch here (`man git-branch`), and send a pull request

repository: Tatsh/ansible-php

repo_name: Tatsh/ansible-php


text:
[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/casperbh96/Activation-Functions-Search/blob/master/Experiment_Activation_Functions.ipynb)

# Activation-Functions-Search
This is code for the article [over at ML From Scratch](https://mlfromscratch.com/activation-functions-explained/) on activation functions.


text:
# Testing the doc site locally

To test this doc site locally,
make sure you have the requirements installed as described
on Github's [Setting up your GitHub Pages site locally with Jekyll](https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/#requirements) article.

Then run from your local clone of `commcare-cloud`, run

```bash
cd docs
bundle install
```
 to install the dependencies and
 ```bash
 bundle exec jekyll serve
 ```
 to serve the doc site locally.