text:
---
layout: location
title: Le Fer Residence Hall
year: 1923
style: Renaissance Revival, Mediterranean influences
architect: D.A. Bohlen and Son
photo-1: Le-Fer-Hall-exerior-front.jpg
alt-1: Exterior view of the front of Le Fer Hall
photo-2: Le-Fer-Hall-aerial.jpg
alt-2: Aerial view of Le Fer Hall
photo-3: Le-Fer-Hall-stairs.jpg
alt-3: The main entryway of Le Fer Hall
photo-4: Le-Fer-Hall-Stained-Glass.jpg
alt-4: The stained glass window above the main starcase in Le Fer Hall
photo-5: Le-Fer-Hall-Exterior-Decor.jpg
alt-5: Detail view of exterior decoration on Le Fer Hall
map: https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d232.47225236170925!2d-87.4623991617915!3d39.50545832374405!2m3!1f0!2f39.40921949190794!3f0!3m2!1i1024!2i768!4f35!3m3!1m2!1s0x886d6387141a54e1%3A0xb2f30758f7857f8!2sLe%20Fer%20Hall!5e1!3m2!1sen!2sus!4v1568397496141!5m2!1sen!2sus
---
Named in honor of Sisters Saint Francis Xavier and Mary Joseph Le Fer (de la Motte), two of Saint Mother Theodore Guerin’s companions, the four-story Le Fer Residence Hall was built or warm yellow brick with stone accents, at a cost of $1M over two years. The twin towers of the central façade create a vertical focal point to the horizontal mass of the building. Beaux Arts influences are found in the profusion of detail that leads the eye up wide steps, past elaborate iron lamps and stone and iron balconies. The Classical procession continues inside, with terrazzo floors leading through the spacious foyer to a marble grand staircase and richly colored stained glass windows.

repository: joelyoder/smw-historic-district

gha_language: HTML

repo_name: joelyoder/smw-historic-district


text:
# Setup
## Install
```bash
npm install
```

## Database
```bash
#  Assumes your user is the default root (with no password)
mysqladmin -u root create wallet_server
node src/db/models.js
```

# Commands
See "scripts" in [package.json](./package.json)

Example: `npm start` or `npm run [cli|dev]`

Unit tests are run from [@graphene/wallet-sync-client](../../libraries/@graphene/wallet-sync-client)..

# Configure
Update `./.npmrc` if you need to change something:
```sh
# Server Port
@graphene/wallet-server:rest_port = 9080
@graphene/wallet-server:rest_ip_requests_per_hour = 10
#
# Email - tokens have the time in them, expire_min is tested when verifying
@graphene/time-token:expire_min = 10
# wallet-server configuration, see ./package.json => { config: {...} }
@graphene/wallet-server:mail_from =<EMAIL_ADDRESS># Email configuration, see ./bin/email.sh
@graphene/wallet-server:mail_script = ./bin/email.sh
#
# See https://www.npmjs.com/package/busboy and @graphene/rest-api package
@graphene/rest-api:fields = 1024
@graphene/rest-api:fieldSize = 20480
@graphene/rest-api:files = 10
@graphene/rest-api:fileSize = 1024000
# Show GET and POST requests
@graphene/rest-api:debug = false
```
For more, see "config" in [package.json](./package.json)

repository: jcalfee/plasma

branch_name: refs/heads/master

extension: md

license_type: permissive

repo_name: jcalfee/plasma


text:
teamcity-vmgr
=============

Adds an ability to launch a session or call Cadence vManager vAPI REST API dynamically as a step in your build.

This plugin adds an ability to perform REST over HTTP calls to Cadence vManager as a step in your build.

Why this plugin ?
=================
Cadence vManager (starting version 14.1 and above) is now exposing a REST API (vAPI) for performing automation queries and updates for its regression/test and coverage data.  This plugin enables you to add a remote execution for extracting runs information, reports data or even launching new sessions as part of your build process.

Features
========
- [x] Free-style job plugin (can perform all vManager API call).
- [x] Support static/dynamic API calls
- [x] Support dynamic authentication per user id.
- [x] Special build step for performing launch of vsif files dynamically.

Limitations
===========
The plugin support for remote launcing of vsif will be supported for Incisive 14.1 S5 and above.

repository: tyanai/teamcity-vmgr

repo_name: tyanai/teamcity-vmgr


text:
## Copasty
>A cli tool built on node.js that allows the user to copy the contents of a file to clipboard and paste it to the desired file from clipboard using a single command.

[![npm](https://img.shields.io/npm/dm/copasty.svg?style=flat-square)](https://www.npmjs.com/package/copasty)
[![npm](https://img.shields.io/npm/v/copasty.svg?style=flat-square)](https://www.npmjs.com/package/copasty)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/fa54fa38100448f292447ba994499414)](https://www.codacy.com/app/aayush1408/Copasty?utm_source=github.com&utm_medium=referral&utm_content=aayush1408/Copasty&utm_campaign=Badge_Grade)

- cross platform
- works on mac,windows and linux
- works with Command Prompt

### Why copasty??

>Suppose you want to copy the contents of the file and paste it to another file. The process to do the following will be like this (especially in windows)

- Navigate to the file
- Open it
- ctrl + a
- ctrl + c
- Navigate to the file you want to paste the content in.
- Open it
- ctrl + v

> Copasty way of handling it

- ```copasty copy 'path-to-file'```
- ```copasty paste 'path-of-file'```

### Installation

###### Windows
```npm i -g copasty```

###### Linux
```sudo npm i -g copasty ```

### How to use?

>Copy the content to the clipboard of a file using
```
copasty copy 'path-to-the-file'
```

>Paste the content of the clipboard to a file using
```
copasty paste 'path-to-the-file'
```

>For checking the version
```
copasty -V
```

>For help
```
copasty --help
```

license: MIT


text:
# Temporal patterns

## Overview
This software repository contains an experimental software implementation of algorithms for solving a set of restless reachability problems in temporal graphs. The software is written in C programming language.

This version of the source code is realeased for WSDM - 2021 submission titled "Restless reachability in temporal graphs: algebraic methods and applications".

## License
The source code is subject to MIT license.

## Organisation
### source
An implementation of algebraic algorithm for finding restless reachability.
### graph-gen
An implementation of a temporal graph generator.
### datasets
Processed graphs of socio-patterns dataset.

## Using the software
Check `implementation.pdf` for usage details.


text:
# Silex Cache Service Provider

[![Build Status](https://travis-ci.org/euskadi31/CacheServiceProvider.svg?branch=master)](https://travis-ci.org/euskadi31/CacheServiceProvider)
[![SensioLabsInsight](https://insight.sensiolabs.com/projects/e1ce7009-a8ad-4d83-bdf8-45f35ce4922f/mini.png)](https://insight.sensiolabs.com/projects/e1ce7009-a8ad-4d83-bdf8-45f35ce4922f)

This service provider for Silex 2.0 uses the Cache classes from Doctrine
Common to provide a cache service to a Silex application, and other service providers.

## Install

Add `euskadi31/cache-service-provider` to your `composer.json`:

    % php composer.phar require euskadi31/cache-service-provider:~1.0

## Usage

### Configuration

If you only need one application wide cache, then it's sufficient to
only define a default cache, by setting the `default` key in `cache.options`.

The cache definition is an array of options, with `driver` being the
only mandatory option. All other options in the array, are treated as
constructor arguments to the driver class.

The cache named `default` is the cache available through the app's
`cache` service.

```php
<?php

$app = new Silex\Application;

$app->register(new \Euskadi31\Silex\Provider\CacheServiceProvider, [
    'cache.options' => [
        'default' => [
            'driver' => 'apc'
        ]
    ]
]);
```

The driver name can be either:

* A fully qualified class name
* A simple identifier like "apc", which then gets translated to `\Doctrine\Common\Cache\ApcCache`.
* A Closure, which returns an object implementing `\Doctrine\Common\Cache\Cache`.

This cache is then available through the `cache` service, and provides
an instance of `Doctrine\Common\Cache\Cache`:

```php
if ($app['cache']->contains('foo')) {
    echo $app['cache']->fetch('foo'), "<br />";
} else {
    $app['cache']->save('foo', 'bar');
}
```

To configure multiple caches, define them as additional keys in `cache.options`:

```php
$app->register(new \Euskadi31\Silex\Provider\CacheServiceProvider, [
    'cache.options' => [
        'default' => [
            'driver' => 'apc'
        ],
        'file' => [
            'driver' => 'filesystem',
            'directory' => '/tmp/myapp'
        ],
        'global' => [
            'driver' => function() {
                $redis = new \Doctrine\Common\Cache\RedisCache;

                $redis->setRedis($app['redis']);

                return $redis;
            }
        ]
    ]
]);
```

All caches (including the default) are then available via the `caches` service:

```php
$app['caches']['file']->save('foo', 'bar');
```

## License

CacheServiceProvider is licensed under [the MIT license](LICENSE.md).


text:
# Dot Product

An efficient way of comparing two vectors

If __A__ and __B__ are two vectors (and are scaled to unit length) then

__||A||__ = 1 _and_
__||A||__ = 1

_A . B_  is 1 if the vectors are identical and 0 is the are perpendicular to rach other

[<img width="100px" height="100px" src="https://upload.wikimedia.org/wikipedia/commons/thumb/3/3e/Dot_Product.svg/1280px-Dot_Product.svg.png">]()

It is a very efficient way to compare the similarity between two vectors

repository: nurulc/machine-learning

path: /dot product.md

filename: dot product.md

repo_name: nurulc/machine-learning


text:
It is also possible to know how many sounds have been counted by the controller's microphone so far.

##### Characteristics

- The maximum number of sounds counted is 255.
- The parameter value is increased in real-time whenever a sound is detected.
- If a new sound is not detected for a certain period, the value of the "Current Sound Count" parameter is passed to the "Sound Count" parameter, and the "Current Sound Count" parameter is reset to 0.

##### Corresponding RoboPlus Task Command

- Parameter : [Current Sound]

[Current Sound]: /docs/en/software/rplus1/task/programming_02/#current-sound-count

repository: ROBOTIS-GIT/emanual

gha_language: JavaScript

gha_license_id: MIT

repo_name: ROBOTIS-GIT/emanual


text:
# Consuming mfe example

https://ragu-framework.github.io/docs/react/consuming-a-micro-frontend

## Steps to run:

1. Install packages
   ```shell
    yarn
    ```

2. Start the micro-frontend
   ```shell
    yarn ragu-cli dev --file my-mfe.js
    ```

3. Start the application
   ```shell
    yarn start
    ```

**Note: You must keep the `ragu-cli` running when you start the application.**

repository: ragu-framework/docs

branch_name: refs/heads/main

repo_name: ragu-framework/docs


text:
# MageCloudKit Tests

This directory contains automated tests for MageCloudKit. Most of these tests are written in [Go](https://golang.org/) and
use a helper library called [Terratest](https://github.com/gruntwork-io/terratest).

Infrastructure code without automated tests is broken. The tests allow us to expose non-trivial bugs in our modules.

## WARNING

1. Many of these tests create real resources in an AWS account and try to clean those resources up at the
end of a test run. This means they may cost money to run and could potentially destroy production
infrastructure unintentionally. Therefore we recommend you do not run these tests in an AWS account
with production infrastructure.
2.
3. We set `-timeout 60m` on all tests not because they necessarily take that long, but because Go has a default test timeout of 10 minutes, after which it forcefully kills the tests with a `SIGQUIT`, preventing the cleanup
tasks from running. Therefore, we set an overlying long timeout to make sure all tests have enough time to finish and clean up.

## Running the tests

### Prerequisites

- Install the latest version of [Go](https://golang.org/).
- Install [dep](https://github.com/golang/dep) for Go dependency management.
- Install [Terraform](https://www.terraform.io/downloads.html).
- Configure your AWS credentials using one of the [options supported by the AWS
  SDK](http://docs.aws.amazon.com/sdk-for-java/v1/developer-guide/credentials.html). Usually, the easiest option is to set the `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` environment variables.

### One-time setup

Download Go dependencies using dep:

```
cd test
dep ensure
```

### Run tests

```bash
cd test
go test -v -timeout 60m
```

### Run a specific test

To run a specific test called `TestFoo`:

```bash
cd test
go test -v -timeout 60m -run TestFoo
```

repository: ymoukaja/magecloudkit

repo_name: ymoukaja/magecloudkit


text:
## RHAdditions

Various Objective-C categories and additions that have served me well over the years.
Hopefully then can serve you too!

## Licence

Released under the Modified BSD License. (Attribution Required)
<pre>
RHAdditions

Copyright (c) 2011-2013 Richard Heard. All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. The name of the author may not be used to endorse or promote products
derived from this software without specific prior written permission.

IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
</pre>

##Content Overview

###RHARCSupport
Supporting macros to allow for building both with and without ARC enabled.

###RHLoggingSupport
Provides debug and error logging macros.

###NSArray+RHFirstObjectAdditions
Adds a `firstObject` method for balance.

###NSBundle+RHLaunchAtLoginAdditions
Adds support for Launch At Login via `SMLoginItemSetEnabled()`.

###NSImage+RHImageRepresentationAdditions
Adds various (PNG / JPEG / GIF) representations.

###NSObject+RHClassInfoAdditions
Adds a `logClassInfo` method to dump a classes ivars, properties and methods.

###NSString+RHNumberAdditions
Adds a bunch of number methods to better reflect those available on NSNumber.

###NSString+RHRot13Additions
Adds a rot13 method for various "non security related" purposes.

###NSString+RHURLEncodingAdditions
Adds URL encoding methods.

###NSThread+RHBlockAdditions
Adds methods for running blocks on specific threads. Useful when specific tasks need to be performed on a specific thread etc.

###NSView+RHSnapshotAdditions
Provides NSView snapshotting, useful for animations and cover transitions.

###UIView+RHSnapshotAdditions
Provides UIView snapshotting, useful for animations and cover transitions.

###NSWindow+RHResizeAdditions
Adds a method to allow for resizing of a windows contentSize over a specific duration.

###UIApplication+RHStatusBarBoundsAdditions
Adds statusBar width, height and bounds methods.

###UIColor+RHInterpolationAdditions
Provides interpolation between 2 UIColors, useful for frame animations etc.

###UIDevice+RHDeviceIdentifierAdditions
Provides a mac address / sha1 based set of device identifiers.

###UIImage+RHComparingAdditions
Adds pixel level image comparison, supports various thresholds for slight variations in images (eg from colour correction etc.)
Also supports resizing one of the 2 images being compared if they are not the same size, so that a px by px comparison is possible.

###UIImage+RHPixelAdditions
Adds support for accessing the underlying raw pixel data of a UIImage, both in bulk and on a point by point basis.
Returned format is RGBA pre-multiplied as is supported by CoreGraphics.

###UIImage+RHResizingAdditions
Adds support for resizing of UIImages that are backed by a CGImage, preserves rotation metadata and scale.

###UILabel+RHSizeAdditions
Adds some simple `widthForHeight:` etc. methods.

###UIView+RHCompletedActionBadgeAdditions
Adds support for showing a completed action badge from a given view. eg: Upon tapping a submit button and getting a conformation from the server you could show a green checkmark over the submit buttons view.

repository: betacao/RHAdditions

repo_name: betacao/RHAdditions


text:
Notes for vectorizing enumerate_seasons
2019-11-17

We ultimately want a column `season_year` that indicates the "season year" the
observation corresponds to. For seasons that do not include the new year, this
is straightforward: `season_year` is the year from the `date` column. _However_
if the season includes the new year, e.g. season is 15 November through 15
February, it requires a little more information. We are using the year the
season _starts in_ as the value to use for `season_year`. So for a season
defined by 15 November 1983 - 15 February 1984, the value for `season_year` will
be 1983.

```
ids <- factor(c("Site 1", "Site 1", "Site 1", "Site 1", "Site 1", "Site 1"))
dates <- c("1983-11-30", "1984-1-30", "1984-03-30", "1984-11-30", "1985-1-30", "1985-03-30")
dates <- as.Date(dates)
values <- c(1, 1, 4, 3, 6, 9)
test_long <- data.frame(y4_hhid = ids,
                        date = dates,
                        value = values)
```

start_month is 11
end_month is 02
day is 15

OBSY is year of the observation

## Case 1
start_month is 11
end_month is 02
day is 15
1983-11-30     # In season
+ greater than OBSY-11-15
+ greater than OBSY-02-15
+ season_year is OBSY
1984-01-30     # In season
+ less than OBSY-11-15
+ less than OBSY-02-15
+ season_year is OBSY - 1
1984-03-30     # Out of season
+ less than OBSY-11-15
+ greater than OBSY-02-15

## Case 2
start_month is 02
end_month is 11
day is 15
1983-11-30     # Out of season
+ greater than OBSY-11-15
+ greater than OBSY-02-15
1984-01-30     # Out of season
+ less than OBSY-11-15
+ less than OBSY-02-15
1984-03-30     # In season
+ less than OBSY-11-15
+ greater than OBSY-02-15
+ season_year is OBSY

repository: themacfreezie/wxsumR

repo_name: themacfreezie/wxsumR


text:
## Mojibake-Python ##

Dockerfile based off ardinor/centos-python3.4.2 that makes creates a container for the blogging engine [MØjibДĸe](https://github.com/ardinor/mojibake)

TO DO:
Check for the db container like https://github.com/dominionenterprises/tol-api-php/blob/master/tests/provisioning/set-env.sh#L17

repository: osboo/dockerfiles

repo_name: osboo/dockerfiles


text:
# Architecture

_This document describes the high-level architecture of Metalang99._

## Interpreter

The interpreter interprets the core metalanguage described in the [specification].

[specification]: https://github.com/Hirrolot/metalang99/blob/master/spec/spec.pdf

### `eval/eval.h`

`eval/eval.h` exposes a single macro `ML99_PRIV_EVAL` which evaluates a given metaprogram. It is implemented as a machine in [continuation-passing style] which is described in the specification too.

[continuation-passing style]: https://en.wikipedia.org/wiki/Continuation-passing_style

### `eval/rec.h`

`eval/rec.h` contains a macro recursion engine upon which everything executes.

## Standard library

The Metalang99 standard library is a set of functions implemented using the core metalanguage. They are located inside corresponding files listed at the [documentation]'s front page.

[documentation]: https://metalang99.readthedocs.io/en/latest/


text:
### Rental Agreement Smart contract V1.0

1. Parameters of the agreement:

```
address authority,
address tenant,
address landlord,

uint startDate,
uint isTerminated,
uint paymentPeriod,
uint numberOfPeriods,
uint rentPerPeriod,
uint paymentDeadlineSincePeriodStart,
uint public maximumLatePaymentDuration;

uint depositAmount
```

2. The agreement is considered "active" after the `landlord` signed the agreement and the `tenant` sent the deposit (`depositAmount` in Ethers).

3. `startDate` (in Unix timestamp) is the starting time of the rental.

4. Every `paymentPeriod` (in seconds), the `tenant` must pay the `rentPerPeriod` (in Ethers) before the payment deadline for that payment period, which is `paymentDeadlineSincePeriodStart` seconds from the start of that particular period.

5. The `tenant` can pay rent in advance

6. The agreement can be terminated in these scenarios:
    * 6a. If the tenant fails to pay the rent within `maximumLatePaymentDuration` (in seconds) from the payment deadline, the landlord can terminate it. The landlord keeps the deposit in this case. The last period of rental that the tenant can stay until would be the last period that the deposit could be used to pay for rent.
      * For example: the payment period is every month. The tenant paid until May 2019, but is late for June 2019 rent payment. If the deposit is 1.5 times the rent, the landlord can terminate the agreement and the tenant can only stay until June 2019 (the deposit could be used to pay for the last month of rent).

    * 6b. Either party can terminate the agreement at least `terminationNotice` (in seconds) before the last payment deadline of the last rental period. The deposit minus the last payment(s) (if not already paid) will be returned to the tenant. The landlord will receive the last payment(s) as well.

      * For example: the payment period is every month. The payment deadline is the 8th day of the month. The notice period is 45 days. Lets say the tenant terminates the agreement on 15th May, 45 days after that would be 29th June. Hence, the last payment date would be the 8th of July. The last rental period would be July. The tenant would need to pay the rent for June and July as well.

    * 6c. The `authority` can terminate the agreement anytime, while specifying how much of the deposit will go to the `tenant` and `landlord`

7. After the last payment, the deposit will be returned to the tenant, and the agreement is no longer active

repository: mrenoon/RentalContract

repo_name: mrenoon/RentalContract


text:
# Guzzle Log Middleware

[![codecov](https://codecov.io/gh/gmponos/guzzle-log-middleware/branch/master/graph/badge.svg)](https://codecov.io/gh/gmponos/guzzle-log-middleware)
[![Total Downloads](https://img.shields.io/packagist/dt/gmponos/guzzle_logger.svg)](https://packagist.org/packages/gmponos/guzzle_logger)
[![Build Status](https://travis-ci.org/gmponos/guzzle-log-middleware.svg?branch=master)](https://travis-ci.org/gmponos/guzzle-log-middleware)
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/gmponos/monolog-slack/blob/master/LICENSE.md)

This is a middleware for [guzzle](https://github.com/guzzle/guzzle) that will help you automatically log every request
and response using a PSR-3 logger.

The middleware is functional with version 6 of Guzzle.

## Install

Via Composer

``` bash
$ composer require gmponos/guzzle_logger
```

## Usage

### Simple usage

```php
use GuzzleLogMiddleware\LogMiddleware;
use GuzzleHttp\HandlerStack;

$logger = new Logger();  //A new PSR-3 Logger like Monolog
$stack = HandlerStack::create(); // will create a stack stack with middlewares of guzzle already pushed inside of it.
$stack->push(new LogMiddleware($logger));
$client = new GuzzleHttp\Client([
    'handler' => $stack,
]);
```

From now on each request and response you execute using `$client` object will be logged.
By default the middleware logs every activity with level `DEBUG`.

### Advanced initialization

The signature of the `LogMiddleware` class is the following:

```php
\GuzzleLogMiddleware\LogMiddleware(
    \Psr\Log\LoggerInterface $logger,
    \GuzzleLogMiddleware\Handler\HandlerInterface $handler = null,
    bool $onFailureOnly = false,
    bool $logStatistics = false
);
```

- **logger** - The PSR-3 logger to use for logging.
- **handler** - A HandlerInterface class that will be responsible for logging your request/response. Check Handlers sections.
- **onFailureOnly** - By default the middleware is set to log every request and response. If you wish to log
the HTTP messages only when guzzle returns a rejection set this as true or when an exception occurred.
Guzzle returns a rejection when [http_errors](http://docs.guzzlephp.org/en/stable/request-options.html#http-errors) option is set to true.
- **logStatistics** - If you set this option as true then the middleware will also log statistics about the HTTP transaction.

### Handlers

In order to make the middleware more flexible we allow the developer to initialize it with a handler.
A handler is the class that will be responsible for logging the HTTP message and it must implement a `HandlerInterface`.

As an example let's say that we create the following handler:

```php
<?php
namespace GuzzleLogMiddleware\Handler;

use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\RequestInterface;
use GuzzleHttp\TransferStats;
use Psr\Log\LoggerInterface;

/** A simple handler that logs only requests */
final class SimpleHandler implements HandlerInterface
{
    public function log(
        LoggerInterface $logger,
        RequestInterface $request,
        ?ResponseInterface $response = null,
        ?\Throwable $exception = null,
        ?TransferStats $stats = null,
        array $options = []
    ): void {
        $logger->debug('Guzzle HTTP request: ' . \GuzzleHttp\Psr7\str($request));
        return;
    }
}
```

We can pass the handler above during construction of the middleware.

```php
<?php
use GuzzleLogMiddleware\LogMiddleware;
use GuzzleHttp\HandlerStack;

$logger = new Logger();  //A new PSR-3 Logger like Monolog
$stack = HandlerStack::create(); // will create a stack stack with middlewares of guzzle already pushed inside of it.
$stack->push(new LogMiddleware($logger, new SimpleHandler()));
$client = new GuzzleHttp\Client([
    'handler' => $stack,
]);
```

From now on all Requests will be logged. Note that at the example above only requests are logged.

**Important**

If no handler is passed the middleware will initialize it's own handler. At the moment the default one is `MultiRecordArrayHandler`

#### MultiRecordArrayHandler

This is the default handler used from the middleware. This handler uses internally the `FixedStrategy` and logs all request
and responses with level debug. This handler adds a separate log entry for each `Request`, `Response`, `Exception` or `TransferStats`.
The information about each object are added as a `context` array to the log entry.

#### StringHandler

This handler uses internally the `FixedStrategy` and logs all request and responses with level debug. You can initialize this handler
with a custom strategy. This handler adds a separate log entry for each Request, Response, Exception or TransferStats.
The handler converts the objects to strings and the information about each object are added to the `message` of the log entry.

### Log Level Strategies

Strategies are used to define the LogLevel that the handler will use to log each object.

#### FixedStrategy

You can use this strategy to log each HTTP Message with a specific level.

#### StatusCodeStrategy

You can use this strategy to log each HTTP Response with a specific level depending on the status code of the Response.

```php
$strategy = new StatusCodeStrategy(
    LogLevel::INFO, // Default level used for requests or for responses that status code are not set with a different level.
    LogLevel::CRITICAL // Default level used for exceptions.
);
$strategy->setLevel(404, LogLevel::WARNING);
$multiRecordArrayHandler = new MultiRecordArrayHandler($strategy);

$logger = new Logger();  //A new PSR-3 Logger like Monolog
$stack = HandlerStack::create(); // will create a stack stack with middlewares of guzzle already pushed inside of it.
$stack->push(new LogMiddleware($logger, $multiRecordArrayHandler));
$client = new GuzzleHttp\Client([
    'handler' => $stack,
]);
```

### Using options on each request

You can set on each request options about your log.

 ```php
 $client->get('/', [
     'log' => [
         'on_exception_only' => true,
         'statistics' => true,
     ]
 ]);
 ```

- ``on_exception_only`` Do not log anything unless if the response status code is above the threshold.
- ``statistics`` if the `on_exception_only` option/variable is true and this is also true the middleware will log statistics about the HTTP call.

## Change log

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

## Testing

``` bash
$ composer test
```

## Credits

- [George<EMAIL_ADDRESS>- [Contributors](../../contributors)

## License

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

repository: gmponos/guzzle-log-middleware

gha_language: PHP

repo_name: gmponos/guzzle-log-middleware


text:
**Table of Content**

1. TOC
{:toc}

## Information

## How to build waltham-transmitter-plugin

1. Go to AGL build folder and configure your environment. Add
'agl-weston-waltham-remoting' as distro feature.

```
       $ cd $AGL_TOP
       $ source meta-agl/scripts/aglsetup.sh -f -b ${MACHINE_TYPE} [additional_distro_features] agl-weston-waltham-remoting
```

2. Build agl-demo-platform by using bitbake.

3. Clone/download the waltham-transmitter-plugin on your own and build
locally using the build system provided. See README.md file for more
information.

## How to configure weston.ini and GStreamer pipeline

### weston.ini

Add output name, host IP address, port number, and mode key under
'[transmitter-output]' section.
You can speficy multiple [transmitter-output] with different output-name.

```
/* Example_weston.ini - single transmitter-output */
	[transmitter-output]
	name=transmitter-1
	mode=640x720@30
	host=<IP_ADDRESS>
	port=5005
	agl-shell-app-id=<APP_ID>
```

### GStreamer pipeline

You can use GStreamer pipeline as you want.  Connect two boards over ethernet.
2. Assign IP to both boards.
```Example:
	transmitter IP: <IP_ADDRESS>
	waltham-receiver IP: <IP_ADDRESS>
```
3. Check if the simple ping works
```
        $ ping <IP_ADDRESS> (you can also ping vice versa)
```

## Typical issues & Tips

### help functions
You can find the help information of LayerManagerControl command by using

```
$ LayerManagerControl help
```

### waltham-transmitter and waltham-receiver doesn't not communicate

1. Please check ethernet connection. If you assign <IP_ADDRESS> and
   <IP_ADDRESS> for waltham-transmitter and waltham-receiver, you shall ping
   vice versa.

```
/* At waltham-transmitter side */
	$ ping <IP_ADDRESS>

/* At waltham-receiver side */
	$ ping <IP_ADDRESS>
```

2. Make sure that IP address specified in the weston.ini under
   [transmitter-output] matches the waltham-receiver IP address.

3. Make sure that IP address in pipeline.cfg on the transmitter side match the
   waltham-receiver's IP address.


text:
# Cloudinsight Agent Dockerfile

This repository is meant to build the base image for a Cloudinsight Agent container. You will have to use the resulting image to configure and run the Agent.

## Quick Start

The default image is ready-to-go. You just need to set your hostname and LICENSE_KEY in the environment.

```
docker run -d --name cloudinsight-agent -h `hostname` -v /var/run/docker.sock:/var/run/docker.sock -v /proc/:/host/proc/:ro -v /sys/fs/cgroup/:/host/sys/fs/cgroup:ro -e LICENSE_KEY={your_license_key_here} oneapm/docker-oneapm-ci-agent
```

If you are running on Amazon Linux, use the following instead:

```
docker run -d --name cloudinsight-agent -h `hostname` -v /var/run/docker.sock:/var/run/docker.sock -v /proc/:/host/proc/:ro -v /cgroup/:/host/sys/fs/cgroup:ro -e LICENSE_KEY={your_license_key_here}
oneapm/docker-oneapm-ci-agent
```

## Configuration

### Environment variables

A few parameters can be changed with environment variables.

* `TAGS` set host tags. Add `-e TAGS="simple-tag-0,tag-key-1:tag-value-1"` to use [simple-tag-0, tag-key-1:tag-value-1] as host tags.
* `LOG_LEVEL` set logging verbosity (CRITICAL, ERROR, WARNING, INFO, DEBUG). Add `-e LOG_LEVEL=DEBUG` to turn logs to debug mode.
* `PROXY_HOST`, `PROXY_PORT`, `PROXY_USER` and `PROXY_PASSWORD` set the proxy configuration.
* `CI_URL` set the OneAPM intake server to send Agent data to [OneAPM](http://www.oneapm.com)

### Enabling integrations

To enable integrations you can write your YAML configuration files in the `/conf.d` folder, they will automatically be copied to `/etc/cloudinsight-agent/conf.d/` when the container starts.

1. Create a configuration folder on the host and write your YAML files in it.

    ```
    mkdir /opt/cloudinsight-agent-conf.d
    touch /opt/cloudinsight-agent-conf.d/nginx.yaml
    ```

2. When creating the container, mount this new folder to `/conf.d`.
    ```
    docker run -d --name cloudinsight-agent -h `hostname` -v /var/run/docker.sock:/var/run/docker.sock -v /proc/:/host/proc/:ro -v /sys/fs/cgroup/:/host/sys/fs/cgroup:ro -v /opt/cloudinsight-agent-conf.d:/conf.d:ro -e LICENSE_KEY={your_license_key_here} oneapm/docker-oneapm-ci-agent
    ```

    _The important part here is `-v /opt/cloudinsight-agent-conf.d:/conf.d:ro`_

Now when the container starts, all files in ``/opt/cloudinsight-agent-conf.d` with a `.yaml` extension will be copied to `/etc/cloudinsight-agent/conf.d/`. Please note that to add new files you will need to restart the container.

### Build an image

To configure custom checks, or setup integrations straight in the image, you will need to build a Docker image on top of this image.

1. Create a `Dockerfile` to set your specific configuration or to install dependencies.

    ```
    FROM oneapm/docker-oneapm-ci-agent
    # Example: MySQL
    ADD conf.d/mysql.yaml /etc/cloudinsight-agent/conf.d/mysql.yaml
    ```

2. Build it.

    `docker build -t cloudinsight-agent-image .`

3.  It's done!

## Information

To display information about the Agent's state with this command.

`docker exec cloudinsight-agent service cloudinsight-agent info`

Warning: the `docker exec` command is available only with Docker 1.3 and above.

## Logs

### Copy logs from the container to the host

That's the simplest solution. It imports container's log to one's host directory.

`docker cp cloudinsight-agent:/var/log/cloudinsight-agent /tmp/log-cloudinsight-agent`

### Supervisor logs

Basic information about the Agent execution are available through the `logs` command.

`docker logs cloudinsight-agent`

## Limitations

Docker isolates containers from the host. As a result, the Agent won't have access to all host metrics.

Known missing/incorrect metrics:

* Network
* Process list

Also, several integrations might be incomplete.

repository: oneapm/docker-oneapm-ci-agent

gha_language: Shell

repo_name: oneapm/docker-oneapm-ci-agent


text:
FS2: Functional Streams for Scala
=============

[![Continuous Integration](https://github.com/functional-streams-for-scala/fs2/workflows/Continuous%20Integration/badge.svg)](https://github.com/functional-streams-for-scala/fs2/actions?query=workflow%3A%22Continuous+Integration%22)
[![Discord](https://img.shields.io/discord/632277896739946517.svg?label=&logo=discord&logoColor=ffffff&color=404244&labelColor=6A7EC2)](https://discord.gg/9V8FZTVZ9R)
[![Maven Central](https://img.shields.io/maven-central/v/co.fs2/fs2-core_2.13)](https://maven-badges.herokuapp.com/maven-central/co.fs2/fs2-core_2.13)

### Overview

FS2 is a library for purely functional, effectful, and polymorphic stream processing library in the [Scala programming language](https://scala-lang.org).
Its design goals are compositionality, expressiveness, resource safety, and speed.
The name is a modified acronym for **F**unctional **S**treams for **Scala** (FSS, or FS2).

FS2 is available for Scala 2.12, Scala 2.13, Scala 3, and [Scala.js](http://www.scala-js.org/) and [Scala Native](https://scala-native.org/).
FS2 is built upon two major functional libraries for Scala, [Cats](https://typelevel.org/cats/), and [Cats-Effect](https://typelevel.org/cats-effect/).
Regardless of those dependencies, FS2 core types (streams and pulls) are polymorphic in the effect type (as long as it is compatible with `cats-effect` typeclasses),
and thus FS2 can be used with other effect libraries, such as [Monix](https://monix.io/).

### Getting Started

Quick links:

* [Microsite][microsite]
* [About the library](#about)
* [How to get latest version](https://fs2.io/#/getstarted/install)
* [API docs][api]
* [Docs and getting help](#docs)

[microsite]: http://fs2.io
[api]: https://www.javadoc.io/doc/co.fs2/fs2-docs_2.13/latest/fs2/index.html
[io-api]: https://oss.sonatype.org/service/local/repositories/releases/archive/co/fs2/fs2-io_2.13/3.1.0/fs2-io_2.13-3.1.0-javadoc.jar/!/fs2/io/index.html
[rx-api]: https://oss.sonatype.org/service/local/repositories/releases/archive/co/fs2/fs2-reactive-streams_2.13/3.1.0/fs2-reactive-streams_2.13-3.1.0-javadoc.jar/!/fs2/interop/reactivestreams/index.html

### Documentation and getting help ###

* There are Scaladoc API documentations for [the core library][core-api], which defines and implements the core types for streams and pulls, as well as the type aliases for pipes and sinks. [The `io` library][io-api] provides FS2 bindings for NIO-based file I/O and TCP/UDP networking.
* [The official guide](https://fs2.io/#/guide) is a good starting point for learning more about the library.
* The [documentation page](https://fs2.io/#/documentation) is intended to serve as a list of all references, including conference presentation recordings, academic papers, and blog posts, on the use and implementation of `fs2`.
* [The FAQ](https://fs2.io/#/faq) has frequently asked questions. Feel free to open issues or PRs with additions to the FAQ!
* Also feel free to come discuss and ask/answer questions in [the Typelevel Discord channel](https://discord.gg/9V8FZTVZ9R) and/or on StackOverflow using [the tag FS2](http://stackoverflow.com/tags/fs2). Discord will generally get you a quicker answer.

### Projects using FS2 ###

You can find a list of libraries and integrations with data stores built on top of FS2 here: [https://fs2.io/#/ecosystem](https://fs2.io/#/ecosystem).

If you have a project you'd like to include in this list, please open a PR or let us know in [the Discord channel](https://discord.gg/9V8FZTVZ9R) and we'll add a link to it.

### Acknowledgments ###

[![YourKit](https://www.yourkit.com/images/yklogo.png)](https://www.yourkit.com/)

Special thanks to [YourKit](https://www.yourkit.com/) for supporting this project's ongoing performance tuning efforts with licenses to their excellent product.

### Code of Conduct ###

See the [Code of Conduct](https://github.com/functional-streams-for-scala/fs2/blob/main/CODE_OF_CONDUCT.md).

gha_language: Scala

gha_license_id: NOASSERTION


text:
```@meta
CurrentModule = Interp1d
```

# Interp1d.jl

[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://AtsushiSakai.github.io/Interp1d.jl/stable)
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://AtsushiSakai.github.io/Interp1d.jl/dev)
[![Build Status](https://github.com/AtsushiSakai/Interp1d.jl/workflows/CI/badge.svg)](https://github.com/AtsushiSakai/Interp1d.jl/actions)

[Interp1d](https://github.com/AtsushiSakai/Interp1d.jl) is a Julia package for univariate interpolations.

This package is inspired by [scipy\.interpolate\.interp1d](https://docs.scipy.org/doc/scipy/reference/generated/scipy.interpolate.interp1d.html) function.

# Requirements

Julia 1.6.x or higher.

# How to install

```jl
using Pkg;Pkg.add("Interp1d")
```

and then just import it with `using Interp1d`.

If you want use latest development version,

```jl
using Pkg;Pkg.add(url = "https://github.com/AtsushiSakai/Interp1d.jl.git")
```

# How to use

You can use many kind of univariate interpolations:
```@example
using Interp1d
using PyPlot
xi = collect(0.0:10.0) # x of interpolated points
yi = exp.(-xi./3.0) # y of interpolated points
x = collect(-1.0:0.1:11.0) # sampling points
for mode in INTERP_MODE_LIST # Do interpolations for all modes.
    f = interp(xi, yi, mode) # get an interpolation function
    y = f.(x) # Do interpolation
    plot(x, y, label=string(mode))
end
plot(xi, yi, "xr")
legend()
```
![asll_mode_plot_sample](./assets/all_mode_plot_sample.png)

Details and other tips can be found in the latest documentaion:

- [Interp1d.jl Documentation](https://AtsushiSakai.github.io/Interp1d.jl/stable)

# Index

```@index
```


text:
# Install

## Add repo

```
helm repo add sentry https://sentry-kubernetes.github.io/charts
```

## Without overrides

```
helm install sentry sentry/sentry
```

## With your own values file

```
helm install sentry sentry/sentry -f values.yaml
```

# Upgrade

Read the upgrade guide before upgrading to major versions of the chart.
[Upgrade Guide](docs/UPGRADE.md)

## Configuration

The following table lists the configurable parameters of the Sentry chart and their default values.

Note: this table is incomplete, so have a look at the values.yaml in case you miss something

| Parameter                                     | Description                                                                                | Default                        |
| :-------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------------ | :----------------------------- |
| `user.create`                                 | if `true`, creates a default admin user defined from `email` and `password`                                                                                | `true`                         |
| `user.email`                                  | Admin user email                                                                                |<EMAIL_ADDRESS>         |
| `user.password`                               | Admin user password                                                                                | `aaaa`                         |
| `ingress.enabled`                             | Enabling Ingress                                                                                | `false`                        |
| `ingress.regexPathStyle`                      | Allows setting the style the regex paths are rendered in the ingress for the ingress controller in use. Possible values are `nginx`, `aws-alb`, `gke` and `traefik` | `nginx`                        |
| `nginx.enabled`                               | Enabling NGINX                                                                                | `true`                         |
| `metrics.enabled`                             | if `true`, enable Prometheus metrics                                                                                | `false`                        |
| `metrics.image.repository`                    | Metrics exporter image repository                                                                                | `prom/statsd-exporter`         |
| `metrics.image.tag`                           | Metrics exporter image tag                                                                                | `v0.10.5`                      |
| `metrics.image.PullPolicy`                    | Metrics exporter image pull policy                                                                                | `IfNotPresent`                 |
| `metrics.nodeSelector`                        | Node labels for metrics pod assignment                                                                                | `{}`                           |
| `metrics.tolerations`                         | Toleration labels for metrics pod assignment                                                                                | `[]`                           |
| `metrics.affinity`                            | Affinity settings for metrics                                                                                | `{}`                           |
| `metrics.resources`                           | Metrics resource requests/limit                                                                                | `{}`                           |
| `metrics.service.annotations`                 | annotations for Prometheus metrics service                                                                                | `{}`                           |
| `metrics.service.clusterIP`                   | cluster IP address to assign to service (set to `"-"` to pass an empty value)                                                                                | `nil`                          |
| `metrics.service.omitClusterIP`               | (Deprecated) To omit the `clusterIP` from the metrics service                                                                                | `false`                        |
| `metrics.service.externalIPs`                 | Prometheus metrics service external IP addresses                                                                                | `[]`                           |
| `metrics.service.additionalLabels`            | labels for metrics service                                                                                | `{}`                           |
| `metrics.service.loadBalancerIP`              | IP address to assign to load balancer (if supported)                                                                                | `""`                           |
| `metrics.service.loadBalancerSourceRanges`    | list of IP CIDRs allowed access to load balancer (if supported)                                                                                | `[]`                           |
| `metrics.service.servicePort`                 | Prometheus metrics service port                                                                                | `9913`                         |
| `metrics.service.type`                        | type of Prometheus metrics service to create                                                                                | `ClusterIP`                    |
| `metrics.serviceMonitor.enabled`              | Set this to `true` to create ServiceMonitor for Prometheus operator                                                                                | `false`                        |
| `metrics.serviceMonitor.additionalLabels`     | Additional labels that can be used so ServiceMonitor will be discovered by Prometheus                                                                               | `{}`                           |
| `metrics.serviceMonitor.honorLabels`          | honorLabels chooses the metric's labels on collisions with target labels.                                                                                | `false`                        |
| `metrics.serviceMonitor.namespace`            | namespace where servicemonitor resource should be created                                                                                | `the same namespace as sentry` |
| `metrics.serviceMonitor.scrapeInterval`       | interval between Prometheus scraping                                                                                | `30s`                          |
| `serviceAccount.annotations`                  | Additional Service Account annotations.                                                                                | `{}`                           |
| `serviceAccount.enabled`                      | If `true`, a custom Service Account will be used.                                                                                | `false`                        |
| `serviceAccount.name`                         | The base name of the ServiceAccount to use. Will be appended with e.g. `snuba` or `web` for the pods accordingly.                                                   | `"sentry"`                     |
| `serviceAccount.automountServiceAccountToken` | Automount API credentials for a Service Account.                                                                                | `true`                         |
| `sentry.existingSecret`                       | Existing kubernetes secret to be used for secret key for the session cookie ([documentation](https://develop.sentry.dev/config/#general))                                                                     | `nil`                          |
| `sentry.features.vstsLimitedScopes`           | Disables the azdo-integrations with limited scopes that is the cause of so much pain                                                                                | `true`                         |
| `sentry.web.customCA.secretName`              | Allows mounting a custom CA secret                                                                                | `nil`                          |
| `sentry.web.customCA.item`                    | Key of CA cert object within the secret                                                                                | `ca.crt`                       |
| `symbolicator.api.enabled`                    | Enable Symbolicator                                                                                | `false`                        |
| `symbolicator.api.config`                     | Config file for Symbolicator, see [its docs](https://getsentry.github.io/symbolicator/#configuration)                                                               | see values.yaml                |

## NGINX and/or Ingress

By default, NGINX is enabled to allow sending the incoming requests to [Sentry Relay](https://getsentry.github.io/relay/) or the Django backend depending on the path. When Sentry is meant to be exposed outside of the Kubernetes cluster, it is recommended to disable NGINX and let the Ingress do the same. It's recommended to go with the go to Ingress Controller, [NGINX Ingress](https://kubernetes.github.io/ingress-nginx/) but others should work as well.

## Sentry secret key

If no `sentry.existingSecret` value is specified, for your security, the [`system.secret-key`](https://develop.sentry.dev/config/#general) is generated for you on the first installation and stored in a kubernetes secret.

If `sentry.existingSecret` / `sentry.existingSecretKey` values are provided, those secrets will be used.

## Symbolicator and or JavaScript source maps

For getting native stacktraces and minidumps symbolicated with debug symbols (e.g. iOS/Android), you need to enable Symbolicator via

```yaml
symbolicator:
  enabled: true
```

However, you also need to share the data between sentry-worker and sentry-web. This can be done in different ways:

- Using Cloud Storage like GCP GCS or AWS S3, see `filestore.backend` in `values.yaml`
- Using a filesystem like

```yaml
filestore:
  filesystem:
    persistence:
      persistentWorkers: true
      # storageClass: 'efs-storage' # see note below
```

Note: If you need to run or cannot avoid running sentry-worker and sentry-web on different cluster nodes, you need to set `filestore.filesystem.persistence.accessMode: ReadWriteMany` or might get problems. HOWEVER, [not all volume drivers support it](https://kubernetes.io/docs/concepts/storage/persistent-volumes/#access-modes), like AWS EBS or GCP disks.
So you would want to create and use a `StorageClass` with a supported volume driver like [AWS EFS](https://github.com/kubernetes-sigs/aws-efs-csi-driver)

Its also important having `connect_to_reserved_ips: true` in the symbolicator config file, which this Chart defaults to.

#### Source Maps

To get javascript source map processing working, you need to activate sourcemaps, which in turn activates the memcached dependency:

```yaml
sourcemaps:
  enabled: true
```

For details on the background see this blog post: https://engblog.yext.com/post/sentry-js-source-maps

## Geolocation

[Geolocation of IP addresses](https://develop.sentry.dev/self-hosted/geolocation/) is supported if you provide a GeoIP database:

Example values.yaml:

```yaml

relay:
  # provide a volume for relay that contains the geoip database
  volumes:
    - name: geoip
      hostPath:
        path: /geodata
        type: Directory

sentry:
  web:
    # provide a volume for sentry-web that contains the geoip database
    volumes:
      - name: geoip
        hostPath:
          path: /geodata
          type: Directory

  worker:
    # provide a volume for sentry-worker that contains the geoip database
    volumes:
      - name: geoip
        hostPath:
          path: /geodata
          type: Directory

# enable and reference the volume
geodata:
  volumeName: geoip
  # mountPath of the volume containing the database
  mountPath: /geodata
  # path to the geoip database inside the volumemount
  path: /geodata/GeoLite2-City.mmdb
```

## External Kafka configuration

You can either provide a single host, which is there by default in `values.yaml`, like this:

```yaml
externalKafka:
  ## Hostname or ip address of external kafka
  ##
  host: "kafka-confluent"
  port: 9092
```

or you can feed in a cluster of Kafka instances like below:

```yaml
externalKafka:
  ## List of Hostnames or ip addresses of external kafka
  - host: "<IP_ADDRESS>"
    port: 9092
  - host: "<IP_ADDRESS>"
    port: 9092
  - host: "<IP_ADDRESS>"
    port: 9092
```

# Usage

- [AWS + Terraform](docs/usage-aws-terraform.md)
- [DigitalOcean](docs/usage-digitalocean.md)

repository: sentry-kubernetes/charts

branch_name: refs/heads/develop

gha_language: Mustache

repo_name: sentry-kubernetes/charts


text:
# Relocating a tab

To move/switch the active tab to the right side by `n` times just do:
```
:tabm +<n>
```

To move/switch the active tab to the left side by `n` times, just do:
```
:tabm -<n>
```

**pro tip**: To make relocating a tab more seamless, you can add the operations in your `aliases.vim` using the shortcut of your choice.

repository: jbfrrr/til

repo_name: jbfrrr/til


text:
---
title: "Workflow Syntax"
metaTitle: "Workflow Syntax for Actionsflow"
---

Like the [Github actions workflows](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions), a Actionsflow workflow is a configurable automated process made up of one or more jobs. You must create a YAML file to define your workflow configuration. The Actionsflow configuration format is the same as [Github actions](https://docs.github.com/en/actions/configuring-and-managing-workflows/configuring-a-workflow)'.

Workflow files use YAML syntax and must have either a `.yml` or `.yaml` file extension. If you're new to YAML and want to learn more, see "[Learn YAML in five minutes](https://www.codeproject.com/Articles/1214409/Learn-YAML-in-five-minutes)".

You must store workflow files in the `workflows` directory on your repository.

A typical workflow file `workflow.yml` looks like this:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
jobs:
  ifttt:
    name: Make a Request to IFTTT
    runs-on: ubuntu-latest
    steps:
      - uses: actionsflow/ifttt-webhook-action@v1
        with:
          event: notice
          key: ${{ secrets.IFTTT_KEY }}
          value1: ${{on.rss.outputs.title}}
          value2: ${{on.rss.outputs.contentSnippet}}
          value3: ${{on.rss.outputs.link}}
```

The following doc will give you more details on the workflow syntax:

# `on`

Required. The name of the Actionsflow trigger. Triggers are how your workflows can start automated workflows whenever they add or update something in your workflow.

For a list of available triggers, see "[Triggers](./triggers.md)".

Example using RSS trigger:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
```

**Context and expression syntax for Actionsflow on**:

You can access context information in workflow triggers. You need to use specific syntax to tell Actionsflow to evaluate a variable rather than treat it as a string:

```yaml
${{ <context> }}
```

For now, you can use [`secrets`](https://docs.github.com/en/actions/configuring-and-managing-workflows/creating-and-storing-encrypted-secrets) and [`github`](https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions#github-context), and [`metadata`](#ontriggerconfigmetadata) as trigger's context. The two objects are set by Github actions and you can use them in the trigger config. For example:

```yaml
on:
  telegram_bot:
    token: ${{ secrets.TELEGRAM_BOT_TOKEN }}
```

## `on.<trigger>`

Optional. The trigger's options. The default value is `{}` and you can find the available params in the trigger's documentation.

## `on.<trigger>.config`

Optional. You can use `config` to configure the general options for the Actionsflow trigger. These options are handled by Actionsflow, so all triggers accept these configurations.

For example:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      limit: 15
```

The `config` key has the following options:

## `on.<trigger>.config.every`

Optional, `number` or `string`. The interval of time in which the trigger should run. If the `every` value type is `number`, the unit is minute. The default value is `0`, which means the trigger will be ran once every Github Actionsflow workflow runs. But due to the limitation of the [shortest interval of github actions](https://docs.github.com/en/actions/reference/events-that-trigger-workflows#schedule), generally Actionsflow will run once every 5 minutes.

You can use `number` to specify the interval of time for running a trigger. Using `60`, means the trigger will be ran once every 60 minutes. You can also use a [cron expression](https://en.wikipedia.org/wiki/Cron) for the `every` option. For example, you can use `1 * * * *` to run every 60 minutes (now using the cron expression syntax). We use [`cron-parser`](https://github.com/harrisiirak/cron-parser#readme) to parse cron expression, allowing you to define a more complex trigger schedule.

For example, if you want to run a trigger at 7:00 AM weekly, you can use the following config:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      every: "0 7 * * 1-5"
```

> Note: the default time zone is `UTC`, so if you set a cron expression, you should take that into account. You can also change the time zone by using `on.<trigger>.config.timeZone`.

> Note: webhook events will ignore the `every` config.

## `on.<trigger>.config.timeZone`

Optional. `string`, time zone, the default value is `UTC`, used for parsing `on.<trigger>.config.every` cron expression, see more time zone string at [here](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).

## `on.<trigger>.config.metadata`

Optional, `string`, js function code, the default value is `return {}`, the returned value will be used for the trigger's value context, for example:

```yaml
on:
  poll:
    url: https://jsonplaceholder.typicode.com/posts?page=${{metadata.page}}
    config:
      metadata: |
        return {
          page: 2
        }
```

## `on.<trigger>.config.filter`

Optional, [`MongoDB query language`](https://docs.mongodb.com/manual/reference/operator/query/). You can use `filter` to filter the trigger's results as you need.

Actionsflow use [`mingo`](https://github.com/kofrasa/mingo)(A tool to use MongoDB query language for in-memory objects) for filter the trigger's results. For example, the following workflow will only be triggered when RSS feed `title` contains `interviews`:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      filter:
        title:
          $regex: interviews
```

Example for not include `interviews`

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      filter:
        title:
          $not:
            $regex: interviews
```

Learn more about MongoDB query language, please see [`MongoDB query documents`](https://docs.mongodb.com/manual/tutorial/query-documents/index.html) and [`mingo`](https://github.com/kofrasa/mingo).

## `on.<trigger>.config.filterOutputs`

Optional, [`MongoDB query language projection syntax`](https://docs.mongodb.com/manual/reference/method/db.collection.find/index.html#find-projection). You can use `filterOutputs` to filter the results fields of the trigger's outputs as you need.

Actionsflow uses [`mingo`](https://github.com/kofrasa/mingo) (a tool to use MongoDB query language for in-memory objects) to filter the trigger's outputs. For example, the following email trigger outputs which include `date`, `subject`, and `subject` will only [include the first 7 bytes](https://docs.mongodb.com/manual/reference/operator/aggregation/substrBytes/):

```yaml
on:
  email:
    imap:
      host: outlook.office365.com
      user: ${{secrets.EMAIL_USER}}
      password: ${{secrets.EMAIL_PASSWORD}}
    config:
      filterOutputs:
        date: 1
        subject:
          $substrBytes:
            - $subject
            - 0
            - 7
```

The resulting `outputs` when the trigger runs will include `date`, `subject` key:

```json
{
  "outcome": "success",
  "conclusion": "success",
  "outputs": {
    "date": "2020-09-15T21:14:26.000Z",
    "subject": "Hello"
  }
}
```

To learn more about MongoDB query projection syntax, please see [`MongoDB query language projection syntax`](https://docs.mongodb.com/manual/reference/method/db.collection.find/index.html#find-projection) and [`mingo`](https://github.com/kofrasa/mingo).

## `on.<trigger>.config.filterScript`

Optional, `string`, javascript code, like [Array.prototype.filter()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter), you need to return `true` to keep the item. You can use `item`, `index`, `items` variable. `filterScript` will be called after `filter`. This For example:

```yaml
on:
  poll:
    url: https://jsonplaceholder.typicode.com/posts
    config:
      filterScript: |
        if(item.title.includes('accusamus')){
          return true
        }
```

## `on.<trigger>.config.format`

Optional, `js function code`. You can use `format` to filter results fields of the trigger's outputs as you need. `format` will be called after `filterOutputs`. You can use `format` like this:

```yaml
name: A really complex example
on:
  poll:
    url: https://jsonplaceholder.typicode.com/posts
    config:
      format: |
        item.title = item.title.substring(0,5)
        return item;
```

## `on<trigger>.config.outputsMode`

Optional, available value is `separate` or `combine`, the default value is `separate`. For example, if a RSS trigger fetched 5 items once, if `outputsMode` is `separate`, then jobs of your workflow will be called 5 times with single item every time. If `outputsMode` is `combine`, then the jobs will be called only once, and the `outputs` will be an array witch includes 5 items. Such like daily digest is recommended to use `combine` mode.

With `separate`:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
jobs:
  print:
    name: Print
    runs-on: ubuntu-latest
    steps:
      - name: Print Outputs
        env:
          title: ${{on.rss.outputs.title}}
        run: |
          echo title: $title
```

With `combine`

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      outputsMode: combine
jobs:
  print:
    name: Print
    runs-on: ubuntu-latest
    steps:
      - name: Print Outputs
        env:
          title: ${{on.rss.outputs[0].title}}
          length: ${{ on.rss.outputs.length }}
        run: |
          echo title: $title
          echo length: $length
```

## `on.<trigger>.config.resultsPerWorkflow`

Optional, `number` or `undefined`, the default is `undefined`, you can define the built workflow jobs length, if `undefined`, all outputs will be build to one single workflow. Generally, if your source data is large, you can use `resultsPerWorkflow` to separate the built workflow files to save space.

## `on<trigger>.config.exportOutputs`

Optional, `boolean`, the default is `false`, sometimes the outputs are too large for act to handle, especially when using `outputsMode: "combine"`, for the situation, you can choose to export outputs to file, then, the outputs will only include a `path`, you can use the `path` to read the outputs file, for example:

> Note, you should use [`--bind`](https://github.com/nektos/act#flags) for run [`act`](https://github.com/nektos/act), then you can access the outputs files at `act` workspace. Change `.github/workflows/actionsflow.yml`, `act` step, add `--bind` param. For local, change your start script to `actionsflow start -- --bind`

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      outputsMode: combine
      exportOutputs: true
jobs:
  outputs:
    name: outputs
    runs-on: ubuntu-latest
    steps:
      - name: Get outputs
        uses: actions/github-script@v2
        env:
          OUTPUTS_PATH: ${{ on.rss.outputs.path }}
        with:
          script: |
            const outputs = require(`${process.env.GITHUB_WORKSPACE}/${process.env.OUTPUTS_PATH}`)
            console.log('outputs',outputs)
            return true
```

## `on<trigger>.config.outputsDir`

Optional, if `on<trigger>.config.exportOutputs` is `true`, then you can specify the outputs directory, the default value is `<dest>/outputs`

## `on.<trigger>.config.sort`

Optional, [`MongoDB query language sort syntax`](https://docs.mongodb.com/manual/reference/method/cursor.sort/index.html). You can use `sort` to change the order of the trigger's results as you need.

Actionsflow uses [`mingo`](https://github.com/kofrasa/mingo) (a tool to use MongoDB query language for in-memory objects) to sort the trigger's results. For example, the following workflow will sort the triggers results by descending order:

```yaml
on:
  poll:
    url: https://jsonplaceholder.typicode.com/posts
    config:
      limit: 1
      sort:
        id: -1
```

## `on.<trigger>.config.sortScript`

Optional, `string`, javascript code, like [Array.prototype.sort()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort), you need to return `number` like `-1`, `0`, `1` to sort items. You can use `a`, `b`, `items` variable. `sortScript` will be called after `sort`. This For example:

```yaml
on:
  poll:
    url: https://jsonplaceholder.typicode.com/posts
    config:
      sortScript: |
        return a.id-b.id
```

## `on.<trigger>.config.limit`

Optional, `number`. The trigger's results max length. The default value is `undefined`, which means the trigger will handle all items.

## `on.<trigger>.config.skip`

Optional, `number`. Skip `<count>` results of the trigger's results. The default value is `undefined`, which means the trigger will handle all items.

## `on.<trigger>.config.active`

Optional, `boolean`. Configures whether the trigger is active (defaults to `true`). You can deactivate triggers by setting `active: false`.

## `on.<trigger>.config.skipFirst`

Optional, `boolean`. Configures whether the trigger skips the first time data is obtained. If `true`, the trigger will run the next time it get data. The default value is `false`.

## `on.<trigger>.config.shouldDeduplicate`

Optional, `boolean`. Configures if the trigger's results should be deduplicated. The default value is dictated by the trigger. You use this setting to override the trigger's default configuration.

## `on.<trigger>.config.manualRunEvent`

Optional, `string` or `string[]`. Github actions events that should trigger this trigger to run manually. The default value is `[]`, but you can use `push`, `workflow_dispatch` and `repository_dispatch` as values.

For example, if you set a trigger's `every` configuration as `1 2 * * *` and you don't want to wait to `02:01` to test your trigger, you can config `workflow_dispatch` as a trigger's `manualRunEvent`. Then, if a [`workflow_dispatch`](https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#workflow_dispatch) event occurs, your trigger will be triggered.

## `on.<trigger>.config.force`

Optional, `boolean`. Whether to force data to be updated. If `true`, the trigger will ignore cache, `every`, and last update time. The default value is `false`. You can set this `true` to debug, replay your workflow.

## `on.<trigger>.config.skipOnError`

Optional, `boolean`. Set to `true` for Actionsflow to ignore the error of this trigger when it runs and fails. The default value is `false`, Actionsflow will throw an error finally, Github may send an email to notice you the error.

## `on.<trigger>.config.buildOutputsOnError`

Optional, `boolean`. Set to `true`, Actionsflow will build a workflow with `on.<trigger>.outcome` as `true`, `on.<trigger>.outputs` as `{}` from failing when a trigger fails. The default value is `false` - Actionsflow will skip the build outputs for this trigger this time.

## `on.<trigger>.config.logLevel`

Optional, `string`. Log level for trigger. The default value is `info` but you can use `trace`, `debug`, `info`, `warn` and `error`.

## `on.<trigger>.config.debug`

Optional, `boolean`. Whether the trigger enables debug mode or not. The default value is `false`. If `true`, then the `logLevel` will be `debug`, and the trigger will be triggered when any event occurs (like `push`, `workflow_dispatch`, `repository_dispatch`).

## `on.<trigger>.config.skipSchedule`

Optional, `boolean`. Whether the trigger should skip schedule event. The default is `false`. If `true`, the trigger will ignore the `every` param and not run when triggered by the `schedule` event. Use this param when you want a trigger to run only manually.

## `on.<trigger>.<param>`

Optional. The trigger's options, defined by the specific trigger. You should read the trigger's documentation to see all available options for the trigger. For example, for the [`rss`](./triggers/rss.md) trigger:

```yaml
on:
  rss:
    url: https://hnrss.org/newest?points=300
    config:
      limit: 15
```

# `jobs`

A workflow run is made up of one or more jobs. Jobs run in parallel by default. To run jobs sequentially, you can define dependencies on other jobs using the `jobs.<job_id>.needs` keyword.

The jobs configuration format is the same as [Github actions jobs](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobs), so you can learn more about them [here](https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobs).

Actionsflow supports almost all [Github actions](https://github.com/marketplace?type=actions) by using [act](https://github.com/nektos/act) (a tool for running GitHub Actions locally).

A typical job looks like this:

```yaml
jobs:
  ifttt:
    name: Make a Request to IFTTT
    runs-on: ubuntu-latest
    steps:
      - uses: actionsflow/ifttt-webhook-action@v1
        with:
          event: notice
          key: ${{ secrets.IFTTT_KEY }}
          value1: ${{ on.rss.outputs.title }}
          value2: ${{ on.rss.outputs.contentSnippet }}
          value3: ${{ on.rss.outputs.link }}
```

For more actions, please see [Awesome Actions List we Collected](./actions.md) and [Github Actions Marketplace](https://github.com/marketplace?type=actions).

**Context and expression syntax for Actionsflow jobs**:

You can access context information in workflow jobs. You need to use specific syntax to tell Actionsflow to evaluate a variable rather than treat it as a string:

```yaml
${{ <context> }}
```

All [Github actions contexts and expressions](https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions) are supported by Actionsflow, and we extend the `on` context for the trigger's results. You can use it like this:

```yaml
${{ on.<trigger>.outputs.<key> }}
```

You can find params and outputs keys supported by the trigger by looking at the trigger's documentation.

All triggers will export the following key:

## `on.<trigger>.outputs`

A map of outputs for a trigger's result item. The trigger's outputs are available on all jobs.

Trigger outputs are `object`s. You can use them like this: `${{ on.telegram_bot.from.first_name }}`

By default, `on.<trigger>.outputs` will always be available, unless you set `buildOutputsOnError` as `true`. When `buildOutputsOnError` is `true`, and the trigger runs with an error, then the outputs will be `{}`. You can use `on.<trigger>.outcome` to check if the trigger is triggering errors. When `on.<trigger>.outcome` is `failure`, then the `on.<trigger>.outputs` will be `{}`.

## `on.<trigger>.outcome`

The result of a completed trigger. Possible values are `success`, `failure`, or `skipped`.

If there is only one trigger on a workflow file, by default, `outcome` will always be `success`. If you set the trigger options `buildOutputsOnError: true` and the trigger runs with an error, the `outcome` will be `failure`, but the final `conclusion` is `success`.

If you set multiple triggers on one workflow, only one trigger's `outcome` is `success`. The other `outcome`s will be `skipped`, so you should use `if: on.<trigger>.outcome === 'success'` to ensure the current `<trigger>.outputs.<key>` is available.

## `on.<trigger>.conclusion`

The result of a completed trigger. Possible values are `success`, or `skipped`.

If there is only one trigger on a workflow file, `conclusion` will always be `success`.

If you set multiple triggers on one workflow, only one trigger's `conclusion` is `success`, the other `conclusion`s will be `skipped`.

# Learn More

For a list of available triggers, see [Trigger List](./triggers.md).

For a list of awesome workflows, see [Awesome Actionsflow Workflows](https://github.com/actionsflow/awesome-actionsflow).

repository: actionsflow/actionsflow

gha_language: TypeScript

repo_name: actionsflow/actionsflow


text:
# A user manages their chat identity

Messaging requires a network of users. Getting started messaging with other people requires knowing people connected to one another. Second to this is discovering and safely connecting to them.

## What we found out in research

* Discoverability of other chat users is sometimes overlooked to [provide more security](application-survey/application-survey/manyverse)
* Users need to start chatting to other users as [quickly and painlessly](application-survey/application-survey/haven) as possible to be engaged with your app

## Design considerations

* Since IPFS can work without a connection to the Internet, there should be an easy way for the user to send a link to connect offline
* Allow the user to set if they are discoverable to other users
* Allow the user to control confirmations of new contacts and chats
* Give the user easier to recover profile key recovery options

### Who is the user and what are their needs

Messaging app user interested in using P2P chat because its more secure and can work without Internet access. There is also concern apps like this will be hard to use.

## Putting it into practice

### Getting started to chat on App Y

The user has downloaded, installed and setup their profile on App Y. They do not have any contacts yet.

![](https://raw.githubusercontent.com/ipfs/mobile-design-guidelines/master/.gitbook/assets/ManagingIdentity-1.png)

### The user views profile

The user views their profile to make sure they are discoverable to colleagues. They also see options for their profile as well as other means how to invite other App Y users to chat. They can invite other users by sending their profile link. They can show the QR code or send the link through Bluetooth, Messaging app or Email.

The user looks at their profile recovery to feel safe about their profile. During onboarding they needed to generate a key. They were then told that they would be able to save a phrase to make new keys if they logged out or lost their phone.

They make sure to uncheck `Require new contact confirmation` so if anyone finds them they don't have to confirm them starting a chat.

![](https://raw.githubusercontent.com/ipfs/mobile-design-guidelines/master/.gitbook/assets/ManagingIdentity-2.png)

> **Design considerations**
>
> Allow the user to set if they are discoverable to other users
>
> Allow the user to control confirmations of new contacts and chats

### The user searches for someone to add as a contact

Their colleague told them to search for their user name \("Bobby124"\) to add them as a contact. The other user made their profile discoverable so it appears in the search result. The user can then send them a message which will appear in the `Chat` screen.

![](https://raw.githubusercontent.com/ipfs/mobile-design-guidelines/master/.gitbook/assets/ManagingIdentity-3.png)

### A chat is started with the contact

After the user found their colleague, they were able to start a chat with them. This is because their colleague didn't need confirmation to start a chat with them.

![](https://raw.githubusercontent.com/ipfs/mobile-design-guidelines/master/.gitbook/assets/ManagingIdentity-4.png)

repository: ipfs/mobile-design-guidelines

repo_name: ipfs/mobile-design-guidelines


text:
# [Sales Tax Calculator](http://alexa.amazon.com/#skills/amzn1.ask.skill.7685a878-7b1b-4bfd-a177-7148cc3df481)
![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png) 0

To use the Sales Tax Calculator skill, try saying...

* *Alexa, ask Sales Tax Calculator one thousand and thirty seven dollars at eight percent*

* *sales tax for one hundred ninety nine dollars and ninety nine cents at four point five percent*

* *sales tax for one hundred point thirty five at twenty point three three percent*

Quickly and accurately calculate total prices including sales tax by asking Alexa!

Works with the Amazon Echo and all Amazon devices that run Alexa and Alexa Skills.

***

### Skill Details

* **Invocation Name:** sales tax calculator
* **Category:** null
* **ID:** amzn1.ask.skill.7685a878-7b1b-4bfd-a177-7148cc3df481
* **ASIN:** B01NADD55R
* **Author:** Aubtin Samai
* **Release Date:** December 1, 2016 @ 09:05:36
* **In-App Purchasing:** No


text:
# braces [![NPM version](https://img.shields.io/npm/v/braces.svg?style=flat)](https://www.npmjs.com/package/braces) [![NPM downloads](https://img.shields.io/npm/dm/braces.svg?style=flat)](https://npmjs.org/package/braces) [![Build Status](https://img.shields.io/travis/jonschlinkert/braces.svg?style=flat)](https://travis-ci.org/jonschlinkert/braces)

Fastest brace expansion for node.js, with the most complete support for the Bash 4.3 braces specification.

## Install

Install with [npm](https://www.npmjs.com/):

```sh
$ npm install braces --save
```

## Features

* Complete support for the braces part of the [Bash 4.3 Brace Expansion](www.gnu.org/software/bash/). Braces passes [all of the relevant unit tests](#bash-4-3-support) from the spec.
* Expands comma-separated values: `a/{b,c}/d` => `['a/b/d', 'a/c/d']`
* Expands alphabetical or numerical ranges: `{1..3}` => `['1', '2', '3']`
* [Very fast](#benchmarks)
* [Special characters](./patterns.md) can be used to generate interesting patterns.

## Example usage

```js
var braces = require('braces');

braces('a/{x,y}/c{d}e')
//=> ['a/x/cde', 'a/y/cde']

braces('a/b/c/{x,y}')
//=> ['a/b/c/x', 'a/b/c/y']

braces('a/{x,{1..5},y}/c{d}e')
//=> ['a/x/cde', 'a/1/cde', 'a/y/cde', 'a/2/cde', 'a/3/cde', 'a/4/cde', 'a/5/cde']
```

### Use case: fixtures

> Use braces to generate test fixtures!

**Example**

```js
var braces = require('./');
var path = require('path');
var fs = require('fs');

braces('blah/{a..z}.js').forEach(function(fp) {
  if (!fs.existsSync(path.dirname(fp))) {
    fs.mkdirSync(path.dirname(fp));
  }
  fs.writeFileSync(fp, '');
});
```

See the [tests](./test/test.js) for more examples and use cases (also see the [bash spec tests](./test/bash-mm-adjusted.js));

### Range expansion

Uses [expand-range](https://github.com/jonschlinkert/expand-range) for range expansion.

```js
braces('a{1..3}b')
//=> ['a1b', 'a2b', 'a3b']

braces('a{5..8}b')
//=> ['a5b', 'a6b', 'a7b', 'a8b']

braces('a{00..05}b')
//=> ['a00b', 'a01b', 'a02b', 'a03b', 'a04b', 'a05b']

braces('a{01..03}b')
//=> ['a01b', 'a02b', 'a03b']

braces('a{000..005}b')
//=> ['a000b', 'a001b', 'a002b', 'a003b', 'a004b', 'a005b']

braces('a{a..e}b')
//=> ['aab', 'abb', 'acb', 'adb', 'aeb']

braces('a{A..E}b')
//=> ['aAb', 'aBb', 'aCb', 'aDb', 'aEb']
```

Pass a function as the last argument to customize range expansions:

```js
var range = braces('x{a..e}y', function (str, i) {
  return String.fromCharCode(str) + i;
});

console.log(range);
//=> ['xa0y', 'xb1y', 'xc2y', 'xd3y', 'xe4y']
```

See [expand-range](https://github.com/jonschlinkert/expand-range) for benchmarks, tests and the full list of range expansion features.

## Options

### options.makeRe

Type: `Boolean`

Deafault: `false`

Return a regex-optimal string. If you're using braces to generate regex, this will result in dramatically faster performance.

**Examples**

With the default settings (`{makeRe: false}`):

```js
braces('{1..5}');
//=> ['1', '2', '3', '4', '5']
```

With `{makeRe: true}`:

```js
braces('{1..5}', {makeRe: true});
//=> ['[1-5]']

braces('{3..9..3}', {makeRe: true});
//=> ['(3|6|9)']
```

### options.bash

Type: `Boolean`

Default: `false`

Enables complete support for the Bash specification. The downside is a 20-25% speed decrease.

**Example**

Using the default setting (`{bash: false}`):

```js
braces('a{b}c');
//=> ['abc']
```

In bash (and minimatch), braces with one item are not expanded. To get the same result with braces, set `{bash: true}`:

```js
braces('a{b}c', {bash: true});
//=> ['a{b}c']
```

### options.nodupes

Type: `Boolean`

Deafault: `true`

Duplicates are removed by default. To keep duplicates, pass `{nodupes: false}` on the options

## Bash 4.3 Support

> Better support for Bash 4.3 than minimatch

This project has comprehensive unit tests, including tests coverted from [Bash 4.3](www.gnu.org/software/bash/). Currently only 8 of 102 unit tests fail, and

## Run benchmarks

Install dev dependencies:

```bash
npm i -d && npm benchmark
```

### Latest results

```bash
#1: escape.js
  brace-expansion.js x 114,934 ops/sec ±1.24% (93 runs sampled)
  braces.js x 342,254 ops/sec ±0.84% (90 runs sampled)

#2: exponent.js
  brace-expansion.js x 12,359 ops/sec ±0.86% (96 runs sampled)
  braces.js x 20,389 ops/sec ±0.71% (97 runs sampled)

#3: multiple.js
  brace-expansion.js x 114,469 ops/sec ±1.44% (94 runs sampled)
  braces.js x 401,621 ops/sec ±0.87% (91 runs sampled)

#4: nested.js
  brace-expansion.js x 102,769 ops/sec ±1.55% (92 runs sampled)
  braces.js x 314,088 ops/sec ±0.71% (98 runs sampled)

#5: normal.js
  brace-expansion.js x 157,577 ops/sec ±1.65% (91 runs sampled)
  braces.js x 1,115,950 ops/sec ±0.74% (94 runs sampled)

#6: range.js
  brace-expansion.js x 138,822 ops/sec ±1.71% (91 runs sampled)
  braces.js x 1,108,353 ops/sec ±0.85% (94 runs sampled)
```

## Related projects

You might also be interested in these projects:

* [expand-range](https://www.npmjs.com/package/expand-range): Fast, bash-like range expansion. Expand a range of numbers or letters, uppercase or lowercase. See… [more](https://www.npmjs.com/package/expand-range) | [homepage](https://github.com/jonschlinkert/expand-range)
* [fill-range](https://www.npmjs.com/package/fill-range): Fill in a range of numbers or letters, optionally passing an increment or multiplier to… [more](https://www.npmjs.com/package/fill-range) | [homepage](https://github.com/jonschlinkert/fill-range)
* [micromatch](https://www.npmjs.com/package/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. | [homepage](https://github.com/jonschlinkert/micromatch)

## Contributing

Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/jonschlinkert/braces/issues/new).

## Building docs

Generate readme and API documentation with [verb](https://github.com/verbose/verb):

```sh
$ npm install verb && npm run docs
```

Or, if [verb](https://github.com/verbose/verb) is installed globally:

```sh
$ verb
```

## Running tests

Install dev dependencies:

```sh
$ npm install -d && npm test
```

## Author

**Jon Schlinkert**

* [github/jonschlinkert](https://github.com/jonschlinkert)
* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)

## License

Copyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).
Released under the [MIT license](https://github.com/jonschlinkert/braces/blob/master/LICENSE).

***

_This file was generated by [verb](https://github.com/verbose/verb), v0.9.0, on May 21, 2016._

repository: jenkins-zh/jenkins-zh

repo_name: jenkins-zh/jenkins-zh


text:
# Setting up a JupyterHub workspace
---------------------------------

This repository tries to give guidelines for setting up a JupyterHub environment, where data-sharing is enabled by a NextCloud-backend and users are authentified with CoreOS’s dex OpenIDConnect Client.

To deploy the system, three different docker-compose yaml files are needed. The OIDC provider should be hosted on a different (virtual-)machine then Nextcloud and Jupyterhub.

To use the provided files, the files have to be adapted at several places. Grep for:

    WHITELISTED_USERS #Users are formated username_conntector\nusername2_connector2\n etc
    DEX_BASE_URL # e.g. <IP_ADDRESS>:5554/dex or domain name plus /dex
    DEX_BASE_URL_AS_CN # e.g. <IP_ADDRESS> or domain name
    DEX_POSTGRES_PASSWORD

    JUPYTERHUB_BASE_URL
    JUPYTERHUB_OAUTH_SECRET
    JUPYTERHUB_ADMIN_PWD
    JUPYTERHUB_CHECKPOINTS_PWD
    JUPYTERHUB_STATE_PWD

    NEXTCLOUD_BASE_URL
    NEXTCLOUD_OAUTH_SECRET
    NEXTCLOUD_ADMIN
    NEXTCLOUD_ADMIN_PWD
    NEXTCLOUD_MYSQL_PWD

    MITRE_BASE_URL
    DEX_CLIENT_ID_MITRE
    DEX_CLIENT_SECRET_MITRE

    DEX_CLIENT_ID_GITHUB
    DEX_CLIENT_SECRET_GITHUB

## Step1:
------

Clone the repository and its submodules:
 ```
git clone https://github.com/maltevogl/jupyterworkspace.git

cd jupyterworkspace

git submodule update --init --recursive
```

The structure should be

    -->jupyterworkspace
        --> forks/jupyterhub
        --> jupyterhub
        --> nextcloud
        --> dexoidc

## Step2:
------

After editing the above mentioned settings, deploy first dexoidc, then nextcloud, then JupyterHub. Depending on your ssl settings, importing a root CA into the nextcloud container might be requiered.

Users are requiered to login first via JupyterHub, as this initiates the user creation and mounts the webdav. After this process the NextCloud frontend can be used with the Dex Oauth Login.

User passwords are set with a uuid, such that login is only possible via the Dex flow. Only the admin user for JupyterHub and Nextcloud have conventional passwords.

repository: maltevogl/jupyterworkspace

repo_name: maltevogl/jupyterworkspace