text:
Contributing
============

Pull requests welcome!

New templating engines should be included in their own module, implement the
`com.sgrailways.examples.templating.core.TemplateProcessor` interface, and
have a corresponding unit test.

Please run `mvn clean install` before submitting, which will run unit tests
in every module and checkstyle verification.

repository: sgrailways/templating-examples

repo_name: sgrailways/templating-examples


text:
### File management routes:

Download a file:
```GET /files/:id```

Upload a file:
```POST /files```

Update a file: (metadata)
```PATCH /files/:id```
Remove a file:
```DELETE /files/:id```

### User routes:

Create a new user:
```POST /signup```

Sign in to File Locker:
```GET /signin```

Sign out of File Locker:
```GET /signout```

Get a list of current user's files:
```GET /userFiles```

Get show stats for all stored files:
```GET /dataStats```

license: MIT

branch_name: refs/heads/master

extension: md

gha_language: JavaScript

license_type: permissive


text:
# LAB - Class 01

## Project: Serer Deployment Practice

### Author: Ricardo Barcenas

### Links and Resources

- [ci/cd](https://github.com/401-advanced-javascript-ricardo-b/server-deployment-practice/actions) (GitHub Actions)
- [Heroku Dev Deployment](https://ricardob-server-deploy-dev.herokuapp.com/)
- [Heroku Production Deployment](https://ricardob-server-deploy-prod.herokuapp.com/)

### Setup

#### `.env` requirements (where applicable)

- `PORT` - 3000

#### How to initialize/run your application (where applicable)

- `npm start` to start the app

#### How to use your library (where applicable)

#### Tests

- How do you run tests?
  -  `npm test` to run the tests
- Any tests of note?

- Describe any tests that you did not complete, skipped, etc

branch_name: refs/heads/main


text:
# Lentinus caespitosus Curr., 1876 SPECIES

#### Status
SYNONYM

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

#### Published in
Trans. Linn. Soc. London, Bot. II 1: 120 (1876)

#### Original name
Lentinus caespitosus Curr., 1876

### Remarks
null

repository: mdoering/backbone

path: /life/Fungi/Basidiomycota/Agaricomycetes/Polyporales/Polyporaceae/Lentinus/Lentinus squarrosulus/ Syn. Lentinus caespitosus/README.md

repo_name: mdoering/backbone


text:
Halo PHP Framework
===

Halo is an extremly simple, open source, mixed MVC-like base for your projects, built using PHP5, by me, Henno Täht, with some help from my students.
It aims to be easy to undestand, effortless to use and using a small footprint.

Released under a BSD license, Halo can be used legally for any open source, commercial, or personal project.

Documentation
------

There is no documentation other than the source code itself. Just start reading from index.php and look at the example files. You will understand the *whole* project in less than an hour, which is the main goal of the project.

Installation
------

git clone Go make your new git project, get the zip, unpack it and try to run it. You'll get some errors. Just do what it suggests. Basically you should copy config.sample.php to config.php and configure it. After that you should set up your MySQL database (sorry, no other databases support ATM).

Reporting bugs
------

If you've stumbled across a bug, please help us out by reporting the bug you have found using Github's Issue tracker. If you'd like to fix it yourself, feel free to fork the project on GitHub and submit a pull request!

repository: carmenhaav/airbnb

repo_name: carmenhaav/airbnb


text:
## FizzBuzz (Challenge 16)
### Write a function called FizzBuzzTree which takes a tree as an argument.
### Without utilizing any of the built-in methods available to your language, determine weather or not the value of each node is divisible by 3, 5 or both, and change the value of each of the nodes respectively.
![image](../../assets/16_fizz_buzz_tree.jpg)

gha_language: Python

gha_license_id: MIT


text:
Walkthrough: Customize a processor to support incremental build
================================================================

During this tutorial, we'll walk through the steps to enable a processor to be incremental.

Step1. Implement @Microsoft.DocAsCode.Plugins.ISupportIncrementalDocumentProcessor interface for the processor
------------------------------------------------------------------------------------

```csharp
public class RtfDocumentProcessor : ISupportIncrementalDocumentProcessor
{
    // to-do: implements IDocumentProcessor

    public virtual string GetIncrementalContextHash()
    {
        // to-do: context related hash. if it changes, incremental build isn't triggered.
    }

    public virtual void SaveIntermediateModel(FileModel model, Stream stream)
    {
        // to-do: the logic to store filemodel
    }

    public virtual FileModel LoadIntermediateModel(Stream stream)
    {
        // to-do: the logic to load filemodel
    }
}
```

Step2. Implement @Microsoft.DocAsCode.Plugins.ISupportIncrementalBuildStep interface for all the plugins plugged in the processor
------------------------------------------------------------------------------------------------------
Plugins are flexible to register customized dependency types by implementing the interface's method @Microsoft.DocAsCode.Plugins.ISupportIncrementalBuildStep.GetDependencyTypesToRegister.

Plugins are also flexible to report dependencies by invoking the methods provided by @Microsoft.DocAsCode.Plugins.IHostService.

```csharp
public class RtfBuildStep : ISupportIncrementalBuildStep
{
    // to-do: implements IDocumentBuildStep

    public bool CanIncrementalBuild(FileAndType fileAndType) => true;

    public string GetIncrementalContextHash() => null;

    public IEnumerable<DependencyType> GetDependencyTypesToRegister() => new[]
    {
        new DependencyType()
        {
            Name = "ref",
            Phase = BuildPhase.Link,
            Transitivity = DependencyTransitivity.None,
        }
    };

    public override void Build(FileModel model, IHostService host)
    {
        //.....
        host.ReportDependencyTo(model, "uid", DependencyItemSourceType.Uid, "ref");
    }
}
```

The above sample registered a dependency type named `ref`, this type of dependency applies during `Link` phase and it isn't transitive. `DocFX` has some reserved dependency types, you can refer to [Reserved Dependency Types](advanced_report_dependency.md#reserved-dependency-types) for more details.

In `Build` step, this plugin reports dependencies of type `ref` by invoking @Microsoft.DocAsCode.Plugins.IHostService 's `ReportDependencyTo` method. @Microsoft.DocAsCode.Plugins.IHostService also provides `ReportDependencyFrom` method you can report reverse dependency.

For more details about how to register your own dependency types and report , you can refer to [Advanced: register and report dependency](advanced_report_dependency.md).

Step3. [Optional]Implement @Microsoft.DocAsCode.Plugins.ICanTraceContextInfoBuildStep interface for plugins that need to access context info
-----------------------------------------------------------------------------------------------------------------------
When building articles, some plugins might need the info of unloaded articles. Incremental Build Framework provides the interface @Microsoft.DocAsCode.Plugins.ICanTraceContextInfoBuildStep, which is the superset of @Microsoft.DocAsCode.Plugins.ISupportIncrementalBuildStep and also contains methods to save/load context info.

```csharp
public class RtfBuildStep : ICanTraceContextInfoBuildStep
{
    // to-do: implements ISupportIncrementalBuildStep

    public void LoadContext(Stream stream)
    {
        // to-do: the logic to load last context info
    }

    public void SaveContext(Stream stream)
    {
        // to-do: the logic to save current context info
    }
}
```

Now you're done! Your processor can run incrementally!

branch_name: refs/heads/dev


text:
# The General Standard

<standard name="General Standard">

## Application

This general standard applies to all software engineering studies that
collect and analyze data. It should be complemented by more specific
guidelines where available.

## Initial Checks (Editor)

Reviewers should only be invited for papers with the following
attributes. By assigning reviewers, the editor/chair/administrator is
confirming that the manuscript meets these criteria:
-   meets venue's requirements (e.g. length, author-blinding,
    appropriate keywords)
-   within the venue's scope
-   meets the minimum level of language quality acceptable to the
    journal
-   cites other scholarly works
-   presents new analysis not previously published in a peer-reviewed
    venue (i.e. preprints are fine)
-   does not include unattributed verbatim published text (i.e.
    plagiarism)

### Initial Checks (Reviewer)

Before beginning to review a paper, assigned reviewers should verify the
following.
-   reviewer has no conflicts of interest; if unsure, check with the
    chair or editor
-   reviewer has sufficient expertise; if unsure, check with the chair
    or editor and clarify what you can(not) evaluate
-   paper is clear enough (in language and presentation) to even review

## Specific Attributes

### Essential Attributes

<checklist name="Essential">

<intro>

- [ ]	states a purpose, problem, objective, or research question
- [ ]	explains why the purpose, problem, etc. is important (motivation)
- [ ]	defines jargon, acronyms and key concepts

<method>

- [ ]	methodology is appropriate (not necessarily optimal) for stated purpose, problem, etc.
- [ ]	describes in detail what, where, when and how data were collected (see the [Sampling Supplement](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/Sampling.md))
- [ ]	describes in detail how the data were analyzed

<results>

- [ ]	presents results
- [ ]	results directly address research questions
- [ ]	enumerates and validates assumptions of statistical tests used (if any)[1](#myfootnote1)

<discussion>

- [ ]	discusses implications of the results
- [ ]	discusses the study's limitations and threats to validity
- [ ]	supports main claims or conclusions with explicit evidence (data/observations) or arguments

<other>

- [ ]	contributes in some way to the collective body of knowledge
- [ ]	language is not misleading; any grammatical problems do not substantially hinder understanding
- [ ]	acknowledges and mitigates potential risks, harms, burdens or unintended consequences of the research (see the ethics supplements for [Engineering Research](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/EthicsEngineering.md), [Human Participants](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/EthicsHumanParticipants.md), or [Secondary Data](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/EthicsSecondaryData.md))
- [ ]	visualizations/graphs are not misleading (see the [Information Visualization Supplement](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/InformationVisualization.md))
- [ ]	complies with all applicable empirical standards

</checklist>

### Desirable Attributes

<checklist name="Desirable">

- [ ]	states epistemological stance[2](#myfootnote2)
- [ ]	summarizes and synthesizes a reasonable selection of related work (not every single relevant study)
- [ ]	clearly describes relationship between contribution(s) and related work
- [ ]	demonstrates appropriate statistical power (for quantitative work) or saturation (for qualitative work)
- [ ]	describes reasonable attempts to investigate or mitigate limitations
- [ ]	discusses study’s realism, assumptions and sensitivity of the results to its realism/assumptions
- [ ]	provides plausibly useful interpretations or recommendations for practice, education or research
- [ ]	concise, precise, well-organized and easy-to-read presentation
- [ ]	visualizations (e.g. graphs, diagrams, tables) advance the paper’s arguments or contribution
- [ ]	clarifies the roles and responsibilities of the researchers (i.e. who did what?)
- [ ]	provides an auto-reflection or assessment of the authors’ own work (e.g. lessons learned)
- [ ]   publishes the study in two phases: a plan and the results of executing the plan (see the [Registered Reports Supplement](https://github.com/acmsigsoft/EmpiricalStandards/tree/master/Supplements))
- [ ]	uses multiple raters, where philosophically appropriate, for making subjective judgments (see the [IRR/IRA Supplement](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/Supplements/InterRaterReliabilityAndAgreement.md))

</checklist>

### Extraordinary Attributes
<checklist name="Extraordinary">

- [ ]	applies two or more data collection or analysis strategies to the same research question (see the [Multimethodology Standard](https://github.com/acmsigsoft/EmpiricalStandards/blob/master/docs/MixedMethods.md))
- [ ]	approaches the same research question(s) from multiple epistemological perspectives
- [ ]	innovates on research methodology while completing an empirical study

</checklist>

## General Quality Criteria

There are no universal quality criteria. Each study should be assessed
against quality criteria appropriate for its methodology, as laid out in
the specific **empirical standards**. Avoid applying inappropriate
quality criteria (e.g. construct validity to a study with no constructs;
internal validity to a study with no causal relationships).

### Examples of Acceptable Deviations

A study can only apply an **empirical standard** if an appropriate
standard exists. If no related standards exist, studies should apply
published guidance. If no appropriate guidance exists, reviewers should
apply the general standard and construct an ad hoc evaluation scheme for
the new method.

## Good Review Practices

Reviewers evaluate a manuscripts' trustworthiness, importance and
clarity. The results must be, primarily, true (trustworthy) and,
secondarily, important. A paper that is trustworthy can be accepted even
if it is not important. A paper that is not trustworthy cannot be
accepted, even if it seems important. Papers that are both trustworthy
and important can have priority. Papers must be clear enough to judge
their trustworthiness and importance. Reviewers should endeavor to:
-   Reflect on and clearly state their own limitations and biases.
-   Clarify which are necessary and which are suggested changes.
    Ideally, separate them.
-   Identify parts of the paper that you cannot effectively judge or did
    not review.

## Reviewing Antipatterns
-   Applying empirical standards in a mechanical, inflexible, box-ticking or gotcha-like manner.
-   Rejecting a study because it uses a methodology for which no specific standard is available.
-   Skimming a manuscript instead of carefully reading each word and inspecting each figure and table.
-   Unprofessional or vitriolic tone, ad hominem attacks, disparaging or denigrating comments.
-   Allowing the authors' identities or affiliations to affect the review.
-   Focusing on superficial details of paper without engaging with its main claims or results.
-   Requesting additional analysis not directly related to a study's purpose or research question,
    leading to results poorly linked to the article’s narrative.
-   Using sub-reviewers when the venue does not explicitly allow it.
-   Using the review to promote the reviewer's own views, theories, methods, or publications.

## Invalid Criticisms
-   Setting arbitrary minimum sample sizes or other data requirements, based on neither power analysis nor theoretical saturation
-   Stating that a study:
    - lacks detail without enumerating missing details;
    - is of low quality without explaining specific problems; or
    - is not new without providing citations to published studies that make **practically identical** contributions.
-   Rejecting a study because it replicates or reproduces existing work
-   Cross-paradigmatic criticism (e.g. attacking an interpretivist study for not conforming to positivist norms).
-   Criticizing a study for limitations intrinsic to that kind of study or the methodology used (e.g. attacking a case study for low generalizability)
-   Rejecting a study because the reviewer would have used a different methodology or design
-   Rejecting a study because it reports negative results

## Research and Reporting Antipatterns
-   Attempting a study without reading, understanding and applying published guidelines for that kind of study.
-   Unreasonably small, underpowered or limited studies.
-   Hypothesizing After Results are Known (HARKing) in ostensibly confirmatory, (post-)positivist research.
-   Reporting only the subset of statistical tests that produce significant results (p-hacking).
-   Reporting---together in one paper---several immature or disjointed studies instead of one fully-developed study.
-   Unnecessarily dividing the presentation of a single study into many papers (salami-slicing).
-   Overreaching conclusions or generalizations; obfuscating, downplaying or dismissing a study's limitations.
-   Mentioning related work only to dismiss it as irrelevant; listing rather than synthesizing related work.
-   Acknowledging limitations but then writing implications and conclusions as though the limitations don't exist

---
<footnote>[1](#myfootnote1) visual methods of checking assumptions are often as good as or better than statistical tests</footnote>

<footnote>[2](#myfootnote2)e.g. positivism, falisificationism, interpretivism, critical realism, postmodernism)</footnote>

</standard>

repository: whasselbring/EmpiricalStandards

repo_name: whasselbring/EmpiricalStandards


text:
PuppetLabs Module for haproxy (phrawzty remix)
==============================================

HAProxy is an HA proxying daemon for load-balancing to clustered services. It
can proxy TCP directly, or other kinds of traffic such as HTTP.

This module is based on Puppetlabs' official HAProxy module; however, it has
been "remixed" for use at Mozilla. There are two major areas where the original
module has been changed :

 * Storeconfigs, while present, are no longer required.
 * The "listen" stanza format has been abandoned in favour of a frontend /
   backend style configuration.

Basic Usage
-----------

A very simple configuration to proxy unrelated Redis nodes :

```puppet
  class { 'haproxy': }

  haproxy::frontend { 'in_redis':
    ipaddress       => $::ipaddress,
    ports           => '6379',
    default_backend => 'out_redis',
    options         => { 'balance' => 'roundrobin' }
  }

  haproxy::backend { 'out_redis':
    listening_service => 'redis',
    server_names      => ['node01', 'node02'],
    ipaddresses       => ['node01.redis.server.foo', 'node02.redis.server.foo'],
    ports             => '6379',
    options           => 'check'
  }
```

Configuring haproxy options
---------------------------

The base `haproxy` class can accept two parameters which will configure basic
behaviour of the haproxy server daemon:

- `global_options` to configure the `global` section in `haproxy.cfg`
- `defaults_options` to configure the `defaults` section in `haproxy.cfg`

Configuring haproxy daemon listener (frontend)
----------------------------------------------

One `haproxy::frontend` defined resource should be defined for each HAProxy
loadbalanced set of backend servers. The title of the `haproxy::frontend`
resource is the key to which balancer members will be proxied to. The
`ipaddress` field should be the public ip address which the loadbalancer will
be contacted on. The `ports` attribute can accept an array or comma-separated
list of ports which should be proxied to the `haproxy::backend` nodes.

Configuring haproxy loadbalanced member nodes (backend)
-------------------------------------------------------

The `haproxy::backend` resource should be defined for every backend service
that is serving loadbalanced traffic. The `listening_service` attribute will
associate it with `haproxy::frontend` directives on the haproxy node.
`ipaddresses` and `ports` will be assigned to the member to be contacted on. If
an array of `ipaddresses` and `server_names` are provided then they will be
added to the config in lock-step.

If you're not using storeconfigs, then `listening_service` is useless - just
put whatever you want in there. :P

Dependencies
------------

 * Tested and built on Ubuntu and CentOS.
 * Requires ripienaar's excellent puppet-concat(https://github.com/ripienaar/puppet-concat) module.

Copyright and License
---------------------

Copyright (C) 2012 [Puppet Labs](https://www.puppetlabs.com/) Inc

Puppet Labs can be contacted at<EMAIL_ADDRESS>
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License.  You may obtain a copy of the
License at

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

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

repository: cashgithubs/dockstack

repo_name: cashgithubs/dockstack


text:
---
published: false
title: "Status Quo and Past"
excerpt: "May 23nd - Thinking about my journey so far"
header:
  teaser: "teaser_unsplash_blurry.jpg"
  image: "header_unsplash_blurry.jpg"
  caption: "Photo credit: [**Unsplash**](https://unsplash.com)"
categories:
  - Personal
tags:
  - update
  - diary

---

{% include base_path %}

## Where am I standing now?

My last eye examination was over a year ago, before I discovered the eye wellness programme. I mostly wear contact lenses, but I will include both glasses and contact lenses values to be able to see a full comparison.

### Last prescription January 2015

*Last glasses prescription:*

|         | Sph   | Cyl   | Ach  | Add  | PD    |
|:--------|:-----:|:-----:|:----:|:----:|:-----:|
| Right   | -7.50 | -0.75 |151   | 0.00 | 29.00 |
| Left    | -7.25 | -0.75 |5     | 0.00 | 29.00 |
|----
{: rules="groups"}

*Last contact lenses prescription:*

|         | PWR   |
|:--------|:-----:|
| Right   | -7.00 |
| Left    | -7.00 |
|----
{: rules="groups"}

Starting from this I already swapped to wearing weaker contact lenses. You can get those online without a prescription and even in some drugstores. I bought in one go lenses in steps from where I stood down to -2.25. I wish I had documented the following stages, so here is a rough outline on my experiences so far. When you start this experiment I realise now, that it is really useful to take notes on observations.

I find it easist to check my eyes on a regular schedule by observing signs during your commute.  You will notice that even during one day the signs can be more or less blurred or readable. This is totally normal, since our vision is actually not as fixed as glass prescriptions want to make us believe.

### May 2015

I first swapped in May 2015 to weaker contact lenses of **-6.00**. In the beginning the blurry vision in the distance wasn't easy to deal with. It was the highest difference and maybe a bit too much to start with. I think it took me a week or two to get used to not seeing focused in the distance anymore. Those first days I got tired very quickly and felt quickly getting headaches as well. Since most days are spend walking the same roads and rooms, it is way more easy to navigate than I first had anticipated. My computer screen at work was originally also slightly too far away for me to be able to read with these weaker lenses. But with a bit of rearranging my desk I was able to stick with it.

### August 2015

Accompanying using the weaker contact lenses I wanted to adopt a daily eye yoga practice. Unfortunately stress at work at various other things kept getting in my way and so I was not noticing much progress for a while.

Once I noticed seeing better again, I moved down another step to *-5.25*. From there it took me roughly another half a year.

### April 2016

After quitting my job to fully focus on my eye coaching and my own health I noticed on a couple of days in April that I could read signs in the underground accross the aisle again. Time to challenge my eyes once more - which is where I am now, wearing contact lenses with *-4.50*. These give me at the moment a similiar vision to where I started with the **-6.00** lenses, so overall I assume I regained one dioptre over this past year. This might not sound much, but to me it really shows that change to the better is possible and gives me motivation to step up the speed now.

### Word of warning

I only allow myself wearing the weaker contact lenses on days when I **do not drive a car or bicycle**! Fortunately those are most of my days. Participating in road traffic needs your full vision and limiting it would endanger yourself and others!


text:
<!--
order: 3
-->

# Messages

In this section we describe the processing of messages for the nft module.

## MsgSend

You can use the `MsgSend` message to transfer the ownership of nft. This is a function provided by the `x/nft` module. Of course, you can use the `Transfer` method to implement your own transfer logic, but you need to pay extra attention to the transfer permissions.

The message handling should fail if:

* provided `ClassID` is not exist.
* provided `Id` is not exist.
* provided `Sender` is not the owner of nft.


text:
---
layout: layouts/swordFish.njk
title: swordFish
date: 2017-01-01T00:00:00.000Z
permalink: /swordFish/index.html
footerMsg1: hello from var footerMsg1 in swordFish.md
eleventyNavigation:
  key: swordFish
  order: 5
---
hello from swordFish file: eleventy-netlify-boilerplate/pages/swordfish.md

> ya gotta stuff pics in folder: static/img/
>eleventy.js has some passthrough logic to upload those images to netlify.

>here is imbedded html in the markdown file:

<img src="../static/img/img_girl.jpg" alt="Girl in a jacket" width="250" height="300">

>I tried inserting the image with markdown instead of imbedded html,
but the image cant be resized.  this duznt work right:
 ``    ![GirlieJacket](/static/img/img_girl.jpg){width=50% height=50% } ``
this works, but who cares?  ``    ![GirlieJacket](/static/img/img_girl.jpg) ``
> what a hassle.

Leave the fancy formatting (css) to the web programmer.

> elventy has a cute possum balloon thing.
Notice the reams of stack overflow questions on it.
I am not feeling the love.

> In the top of markdown files, chris coyier uses front matter:
https://jekyllrb.com/docs/front-matter/
See the top of this file, between the three dash lines.
I notice  github has some awareness of the front matter stuff in a .md file.

>Below is text with a css class of selzClass1

>my text line in markdown with class {.selzClass1}
>I added a markdown plugin:
https://www.npmjs.com/package/markdown-it-attrs
https://www.11ty.io/docs/languages/markdown/#add-your-own-plugins
The intent was to identify the css class when writing in markdown.
But this pollutes markdown.  A purist wants very little in the markdown. Mostly just text.
> I expanded 11ty to get css class to work.
package.json I added markdown-it-attrs to refrence the module
 eleventy.js I added markdown-it-attrs to require the module

``` bulma change color {.has-text-primary} ```
bulma change color {.has-text-primary}

> the end of ```swordfish.md ```

repository: flatbill/eleventy-netlify-kamalaBlu

repo_name: flatbill/eleventy-netlify-kamalaBlu


text:
# reason-hooks-testing-library

Reason bindings for [`react-hooks-testing-library`](https://github.com/mpeyper/react-hooks-testing-library).

## Installation
`npm install --save-dev reason-hooks-testing-library`

Then add `reason-hooks-testing-library` to `bs-dev-dependencies` in your `bsconfig.json`:

```json
{
  "bs-dev-dependencies": ["@glennsl/bs-jest", "reason-hooks-testing-library"]
}
```

## Example

```reason

open Jest;
open Expect;
open ReasonHooksTestingLibrary.Testing;

type counterType = {
  counter: int,
  set: (int => int) => unit,
};
let useCounter = initial => {
  let (counter, set) = React.useState(() => initial);
  {counter, set};
};

describe("useCounter", () => {
  open Result;
  let container = renderHook(() => useCounter(0), ());
  test("counter is 0", () =>
    expect(container->result->current.counter) |> toEqual(0)
  );
  test("counter is 1", () => {
    act(() => container->result->current.set(prev => prev + 1));
    expect(container->result->current.counter) |> toEqual(1);
  });
  test("counter is 2", () => {
    act(() => container->result->current.set(prev => prev + 1));
    expect(container->result->current.counter) |> toEqual(2);
  });
});

```
[More examples](https://github.com/beizhedenglong/reason-hooks-testing-library/tree/master/__tests__)

gha_language: Reason


text:
# Deploying IBM Voice Gateway on Kubernetes or Openshift
Running the IBM Voice Gateway in a Kubernetes environment requires special considerations beyond the deployment of a typical HTTP based application. Because the Voice Gateway relies on SIP for call signaling and RTP for media which require affinity to a specific voice gateway instance, the Kubernetes ingress router needs to be avoided for these protocols. To work around the limitations of the ingress router, the voice gateway containers must be configuered in a `hostNetwork` mode, which means that when a port is opened in either of the voice gateway containers, those identical ports are also opened and mapped on the host machine. This also eliminates the need to define media port ranges in the kubectl configuration file which is not currently supported.

In Kubernetes terminology, a single voice gateway instance equates to a single Pod which contains both a SIP Orchestrator container and a Media Relay container. Only one POD should be deployed per node and the POD should be deploy with `hostNetwork` set to true. This will ensure that the SIP and media ports would be opened on the host VM and visible by the SIP Load Balancer.

## Script details:

* The script deploys one POD per node. If #replicas > #nodes, the extra replicas to be scheduled will remain in a waiting state
* Exposes SIP and media relay ports on the associated VM by setting `hostNetwork` to true
* Auto restart of any failed containers
* It is recommended to use `oc` in place of `kubectl` for an Openshift cluster
* Increase `replica` if you have multiple nodes available
* To make the Voice Gateway pods to deploy on nodes of your choosing refer here: [Assigning Pods to Nodes](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/)
* You can also change image tags from `latest` to the any specific version you want

# Deploying Voice Gateway in multi-tenant mode:

## Prerequisites

### Openshift specific

1) Create a new project:
  ```bash
  oc new-project {namespace}
  ```

1) Add hostaccess SCC to your project:
  ```bash
  oc adm policy add-scc-to-group hostaccess system:serviceaccounts:{namespace}
  ```

### Kubernetes specific:

1) Create a new namespace:
  ```bash
  kubectl create namespace {namespace}
  ```

### For Openshift and Kubernetes

1) Configure properties in tenantConfig.json before deployment.
   - For more information - [Configuring multi-tenancy](https://www.ibm.com/support/knowledgecenter/SS4U29/multitenancy.html)

1) Create secret called tenantconfig from the file tenantConfig.json:
   ```bash
   kubectl create secret generic tenantconfig --from-file=tenantConfig=tenantConfig.json -n {namespace}
   ```

1) If you want to enable recording (Optional):
   - Set ENABLE_RECORDING to true in deploy.yaml and create the recording [PersistentVolume and PersistentVolumeClaim](https://kubernetes.io/docs/concepts/storage/persistent-volumes/) using the recording-pv.yaml and recording-pvc.yaml templates.
   - Update the recording template files  and run the following commands:
     ```bash
     kubectl create -f recording-pv.yaml -n {namespace}
     kubectl create -f recording-pvc.yaml -n {namespace}
     ```
   - Uncomment recording volume and volumeMounts sections of the deploy-multitenant.yaml

1) If you want to use MRCPv2 config file (Optional):
   - More info: [Configuring services with MRCPv2](https://www.ibm.com/support/knowledgecenter/SS4U29/MRCP.html)
   - Create unimrcpConfig secret from the unimrcpclient.xml file using the following command:
     ```bash
     kubectl create secret generic unimrcp-config-secret --from-file=unimrcpConfig=unimrcpclient.xml -n {namespace}
     ```
   - Uncomment the unimrcpconfig volume and volumeMounts sections of the deploy-multitenant.yaml

## (Optional) SSL configuration
- More info: [Configuring SSL and TLS encryption](https://www.ibm.com/support/knowledgecenter/SS4U29/security.html#configuring-ssl-and-tls-encryption)

##### Adding trusted certificates for the SIP Orchestrator (For enabling SSL or Mutual Authentication):
- Create secret from the trust store key file:
  ```
  kubectl create secret generic trust-store-file-secret --from-file=trustStoreFile=myPKCS12File.p12 -n {namespace}
  ```
- Create secret for the SSL Passphrase:
  - Add passphrase in a text file `ssl_passphrase.txt` (Make sure there are no extra spaces or new lines in the text file)
  - Create secret from the text file:
    ```
    kubectl create secret generic ssl-passphrase-secret --from-file=sslPassphrase=ssl_passphrase.txt -n {namespace}
    ```
- Uncomment *ssl-so* in `volumes` and `volumeMounts` section of the deploy-multitenant.yaml
- Uncomment variables `SSL_KEY_TRUST_STORE_FILE`, `SSL_FILE_TYPE` and `SSL_PASSPHRASE` in *deploy.yaml* and set `SSL_FILE_TYPE` to the correct file type.

##### Adding trusted certificates for the Media Relay (For enabling SSL):
- Create secret from client CA certificate file:
  ```
  kubectl create secret generic client-ca-cert-secret --from-file=clientCaCertFile=ca-bundle.pem -n {namespace}
  ```
- Uncomment *ssl-mr* in `volumes` and `volumeMounts` section of the deploy-multitenant.yaml
- Uncomment variable `SSL_CLIENT_CA_CERTIFICATE_FILE` in *deploy-multitenant.yaml*

##### Adding certificates for the Media Relay (For Mutual Authentication):
- Create secret from the SSL client PKCS12 file:
  ```
  kubectl create secret generic ssl-client-pkcs12-file-secret --from-file=clientPkcs12File=myPKCS12File.p12 -n {namespace}
  ```
- Create secret for the SSL Passphrase:
  - Add passphrase in a text file `ssl_client_passphrase.txt` (Make sure there are no extra spaces or new lines in the text file)
  - Create secret from the text file:
    ```
    kubectl create secret generic ssl-client-passphrase-secret --from-file=sslClientPassphrase=ssl_client_passphrase.txt -n {namespace}
    ```
- Uncomment *ssl-mr-mutualauth* in `volumes` and `volumeMounts` section of the deploy-multitenant.yaml
- Uncomment variables `SSL_CLIENT_PKCS12_FILE` and `SSL_CLIENT_PASSPHRASE` in *deploy-multitenant.yaml*

## Install Voice Gateway:

Deploy Voice Gateway using the following command:
```bash
kubectl create -f deploy-multitenant.yaml -n {namespace}
```
## Delete Voice Gateway:

Delete Voice Gateway deployment using one of the following command:
```bash
kubectl delete -f deploy-multitenant.yaml -n {namespace}
```
OR
```bash
kubectl delete vgw -n {namespace}
```


text:
# General properties
Use these properties to import properties from other sources, to link to a program when there is a failure to process the request, and to define the regular expression to identify tokens.

Property | Usage
--- | ---
import = _value_ | Import additional properties.
import.private = _value_ | Import additional properties and prevent the values of these properties from appearing in log files, or being copied using tokens. This is useful if the tokens include passwords such as for mail servers.
onfailure = _program_ | Specify a CICS program to link to if there is a failure to process the request. The program has access to the containers passed to CA1Y and those created by specifying the responsecontainer token in a property.
token.regex = _pattern_ | Specify a regular expression pattern to identify the start and end of a token. Valid patterns are detailed in the Java [Pattern](http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) class. The default pattern starts a token with an opening curly bracket `{` and ends with a closing curly bracket `}`.

## Examples

* Import properties from the named file using the JVM default file encoding.
 ```properties
import={file=/path/standard.properties}
 ```
* Import properties from the named file using the UTF-8 encoding.
 ```properties
import={file=/usr/lpp/ca1y/examples/emailServer.properties:encoding=UTF-8}
 ```
* Import properties from a CICS DOCTEMPLATE resource that is cached in memory upon first use.
 ```properties
import={doctemplate=MyTemplate}
 ```
* Import properties from the named file using UTF-8 encoding and do not log or allow these properties to be copied using tokens.
 ```properties
import.private={file=/usr/lpp/ca1y/examples/emailServer.properties:encoding=UTF-8}
 ```
* An event is sent to an HTTP server defined in a URIMAP. If there is a failure, the SupportPac links to program ERRLOG to log the HTTPCONTENT container to DB2.
 ```properties
http.content=Hello from CICS. {responsecontainer=HTTPCONTENT}
http.urimap=HTTPSERV
onfailure=ERRLOG
 ```
* If you need to replace tokens in JSON data, you will need to change this pattern as JSON uses curly brackets to denote arrays.
 ```properties
token.regex=\\$\\{(.+?)\\}
 ```

repository: cicsdev/cics-event-consumer

gha_language: Java

repo_name: cicsdev/cics-event-consumer


text:
[![Travis CI](https://travis-ci.org/dragonnodejs/dragonnodejs-async.svg?branch=master "Travis CI")]
 (https://travis-ci.org/dragonnodejs/dragonnodejs-async)
[![Dependency Status](https://david-dm.org/dragonnodejs/dragonnodejs-async.svg)](https://david-dm.org/dragonnodejs/dragonnodejs-async)
[![devDependency Status](https://david-dm.org/dragonnodejs/dragonnodejs-async/dev-status.svg)](https://david-dm.org/dragonnodejs/dragonnodejs-async#info=devDependencies)

# DragonNode.js Async
Framework to develop modular and testable Node.js applications
- Separate configuration and implementation of modules
- Service container to use services from other modules or define new services in the modules
- Allow to mock libraries and services for testing modules as independent units
- Group modules to bundles and share them with other developers
- Support asynchronously modules and bundles

## Getting started
[Understand the concept of DragonNode.js with the first steps how to build an application]
 (https://github.com/dragonnodejs/getting-started)

## Create new App
See: [dragonnodejs/app-skeleton](https://github.com/dragonnodejs/app-skeleton.git)

## Create new Bundle
See: [dragonnodejs/bundle-skeleton](https://github.com/dragonnodejs/bundle-skeleton.git)

repository: dragonnodejs/dragonnodejs-async

repo_name: dragonnodejs/dragonnodejs-async


text:
# Hyperlink

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**needElevatedPermissions** | **Boolean** | Whether the operation requires elevated permissions (when the field is present, elevated permissions are required). |  [optional]

repository: aravindputrevu/ess-cloud-sdk-java

repo_name: aravindputrevu/ess-cloud-sdk-java


text:
# ProjetNoSQL

This project consists of three major steps:

1. Download the gdelt csv files to AWS S3 bucket.
2. Transfer the data from S3 to a MongoDB replica set with preprocessing by Spark scala.
3. Explore data stored in MongoDB on AWS with four predefined queries.

The achitechture can be illustrated as :
![Architecure](asset/NoSQL.jpg)

gha_language: Jupyter Notebook


text:
#Minio Cookbook

This is home for recipes of related projects and tools to use with Minio.

### How to Contribute a Recipe

1. Fork this repo and create a new topic branch.
2. Make your addition. See one of the recipe files for a sample.
3. Send a PR - Please include a short descritpion of your new or updated recipe.

Note: You can also refer to [Awesome Minio](https://github.com/minio/awesome-minio) to get your project or use-case listed under Minio.

### List of Recipes

- [Running Deis Workflow with Minio](./use_minio_with_deis.md)
- [AWS CLI with Minio](./aws-cli-with-minio-server.md)
- [AWS Go SDK for Minio](./aws-sdk-go-with-minio-server.md)
- [Running Minio in Docker](./docker_minio.md)
- [Store MongoDB Backups in Minio](./mongo_minio.md)
- [Store MySQL Backups in Minio](./mysql_minio.md)
- [Store PostgreSQL Backups in Minio](./pgsql_minio.md)
- [restic with Minio](./restic_minio.md)
- [s3cmd with Minio](./s3cmd_with_minio_server.md)
- [Aggregate Apache logs with fluentd and Minio](./aggregating-Apache-logs-with-fluentd-and-Minio-server.md)
- [Generate Let's Encypt certificate using Concert for Minio](./generate-Lets-Encypt-certificate-using-Concert-for-Minio.md)
- [Setup Caddy proxy with Minio](./setup-Caddy-proxy-with-Minio-Server.md)
- [Setup Nginx proxy with Minio](./setup-Nginx-proxy-with-Minio-Server.md)

repository: ncw/cookbook

repo_name: ncw/cookbook


text:
## The Situation

After being notified of the fact that a prominent participant in the conference had been convicted of two counts: rape of drugged victim and possession of child pornography, the CppCon conference leadership and the Standard C++ Foundation board went through a secret internal process that resulted in them continuing to promote this person and protect them. When confronted by #include <C++> members, they refused to give any information on the nature of their decision nor to communicate more widely on their policy.

## Executive Summary

[#include <C++>](https://includecpp.org/) is a global community of C++ developers who aim to make the C++ community more
welcoming, open, and inclusive.

[CppCon](https://cppcon.org) is the largest conference for the C++
community. [The Standard C++ Foundation](https://isocpp.org) runs it. #include <C++> has had a presence at the
conference for a number of years.

One of the CppCon organizers and speakers (herein "individual X”, or “X”") has a criminal record.  The Standard C++ Foundation board has been aware of this fact since August 2021 at the latest.

When #include <C++> members reached out to the CppCon organization team to try to get information on what steps were taken to ensure the safety of attendees and the transparency on the situation, they were regularly met with either refusal to answer or request to meet only under non-disclosure agreement. Contradictory answers to the same question from multiple involved parties make us even doubt the decisions were clear enough inside the Standard C++ Foundation board itself.

The actions of CppCon and the Standard C++ Foundation in this matter demonstrate systemic failures. We believe CppCon and the Standard C++ Foundation do not share our values and do not sufficiently prioritize diversity, inclusion, and the safety of the most
vulnerable members of our community. Throughout our exchanges with them, CppCon and the Standard C++ Foundation have used secrecy and
confidentiality to avoid accountability.

\#include <C++> needs a number of meaningful and significant changes to be made to CppCon and the Standard C++ Foundation. Until these changes are made, #include <C++> will cease all collaboration with CppCon.

## Recent CppCon communication

On March 9th 2022 CppCon issued [a statement](https://cppcon.org/announcing-cppcon-safety-policy/) and [a new safety policy](https://cppcon.org/safetypolicy/) in response to these events becoming public. We regret that they waited until the publicity to do so and think that [this statement](https://cppcon.org/announcing-cppcon-safety-policy/) is misrepresenting some facts and incomplete:

* They claim that X was only allowed to participate as an ordinary attendee and was removed from all conference organizational roles. To our knowledge X benefited from multiple advantages that are not given to ordinary attendees (paid hotel room, gift basket) and was still involved in the organization of CppCon as of at least last week.

* The statement and safety policy do not commit to any kind of transparency in the future.

## Mishandlings

At several points during the meetings leading to CppCon’s decision regarding the handling of X’s case, bad decisions were taken. We want to highlight more particularly the following:

* The Standard C++ Foundation board invited individual X to speak to them about their crimes. This was a complete violation of
  their victims' privacy, and incredibly naive. It was disrespectful and inappropriate. A group of people with no specific training and only one side of the story will never be able to make a relevant decision.

* The Standard C++ Foundation president told individual X about the process that #include <C++> was in and who was participating
  in it, causing X to directly contact members of this group. This action was perceived as threatening by members of
  this group, and shows a complete lack of judgment on the part of the board.

* The CppCon Code of Conduct team was circumvented in these decisions and was not given any power on the whole subject.

* The Standard C++ Foundation board “accepted” the resignation of one of its members, who had raised objections to the process and decisions of the board ([tweets](https://twitter.com/chandlerc1024/status/1502521340787527680?s=20&t=lptLBqm_3XnOrtxietEHjQ)). The board member had tendered their resignation in 2020-10, but had been persuaded to stay on for the following year. This acceptance resulted in the board member leaving the board with immediate effect.

## Our Past Involvement

\#include <C++> has been involved with CppCon in a variety of ways:

* \#include <C++> organized and crowdfunded programs to provide tickets and travel grants to attendees from underrepresented groups. CppCon has provided discounted rates for these tickets.

* \#include <C++> hosted dinner events focused on diversity and inclusion at CppCon. At first, these events were held offsite and crowdfunded through by #include <C++>, but in recent years CppCon has incorporated these events into the official conference program and hosted them onsite.

* \#include <C++> ran a booth at CppCon between 2017 and 2019, where we provide information about our organization and sell #include <C++> merchandise. CppCon does not charge us a fee for the booth.

* \#include <C++> is a CppCon Community Sponsor. Community Sponsors do not pay a sponsorship fee.

* \#include <C++> provides several channels on the Discord server for CppCon attendees to discuss, plan social events, and so on. There are also channels used for organizing the booth, dinner, and scholarship program.

* \#include <C++> promotes the conference as a whole and individual conference events and activities on our website, twitter posts, etc and encourages our members to do the same personally.

## Our Response

Until and unless meaningful changes, listed below, are made to the governance of CppCon and the Standard C++ Foundation:

* \#include <C++> has decided to cease all collaboration with CppCon as an organization. This includes all activities listed in the prior section.

* A considerable number of individuals involved or not with #include <C++> have already publicly decided to discontinue their personal involvement in CppCon as organizers, speakers, and attendees.

## What Needs to Change

We believe that CppCon and the Standard C++ Foundation have systemic problems that require reform. We need to see meaningful changes to CppCon and the Standard C++ Foundation before we can participate in CppCon again, specifically:

* Transparency and public accountability from CppCon and the Standard C++ Foundation.

  * A full, public transparency report from the Standard C++ Foundation on this incident.

  * Public annual CppCon Code of Conduct transparency reports.

  * Public minutes for the Standard C++ Foundation board meetings ([following the example of the Python Software Foundation](https://www.python.org/psf/records/board/minutes/)).

  * Public annual reports on the activities and decisions of the Standard C++ Foundation Board ([following the example of the Python Software Foundation](https://www.python.org/psf/annual-report/2021/)).

* Changes to the governance of CppCon.

  * Establishment of a transparent and diverse CppCon Steering Committee that has authority over CppCon. CppCon Attendees should elect the Steering Committee, and have short term limits.

  * Changes to the composition of the Standard C++ Foundation board.

* Empowerment of the CppCon Code of Conduct team.

  * Extension of the mandate of the team to all questions of attendee safety.

  * Possibility for the team to take binding decisions on the conference leadership.

## Changes as a first step

These changes bringing transparency and accountability are a necessary step to bring back trust and make sure everybody is able to take decisions by themselves regarding their security.

It is absolutely possible that decisions taken transparently with the full support of an empowered CppCon Code of Conduct team might not be satisfactory to #include <C++> and that we will still not engage with said conference. But it would at least let attendees make an informed decision for themselves instead of having a small group of people deciding for the whole community.


text:
Configuration Reference
=======================

You have to provide at least the minimum configuration in a YAML file:

```yaml
source_code:
    # Where your source files are located. This should point to the same folder as the rootDirectory
    # that you have configured for the tombstone-logger component.
    root_directory: ./src
logs:
    # Where your tombstone log files are located
    directory: ./logs/tombstones
```

Relative paths in the configuration file are resolved relative to the file's location.

This is an overview of all the configuration options available:

```yaml
# Where your source code is located
source_code:
    # Where your source files are located. This should point to the same folder as the rootDirectory
    # that you have configured for the tombstone-logger component.
    root_directory: ./src

# How the analyzer gets the list of active tombstones
tombstones:
    # Use PHP parser to extract all currently configured tombstones from the source code
    parser:
        # Exclude directories within the source directory (see symfony/finder's "exclude" option)
        # Default: none
        excludes:
          - tests

        # Name pattern of files to be included (see symfony/finder's "name" option)
        # Default: *.php
        names:
          - "*.php7"  # For example

        # Name pattern of files to be excluded (see symfony/finder's "notName" option)
        # Default: none
        not_names:
          - "*Test.php"  # For example

        # Fully qualified name of the tombstone functions
        # If not set, defaults to "tombstone"
        function_names:
          - tombstone                     # A function in the global scope
          - Acme\Tombstone\tombstone      # A function in the Acme\Tombstone namespace
          - Acme\Tombstone\Foo::tombstone # A static method of the Foo class

# How the analyzer gets the tombstone logs
logs:
    # This is the directory where log files from AnalyzerLogHandler are located. All *.tombstone files
    # including sub-directories will be processed.
    directory: logs

    # Alternatively, if you can't write/read logs in the analyzer file format, you can configure a
    # custom log provider, that allows you read read logs from any source in any format.
    custom:
        class: Acme\Tombstone\CustomLogProvider

        # Optional, in case the autoloader doesn't automatically find the class file
        file: src/tombstone/CustomLogProvider.php

# Report generation options. See the "Report Formats" documentation for more details on this.
report:
    php: report/tombstone-report.php   # Generate a PHP dump of the result in this file
    checkstyle: report/checkstyle.xml  # Generate a Checkstyle report in this file
    html: report   # Generate a HTML report in this folder
    console: true  # Display report on the console (default: false)
```

The tool uses [symfony/finder](https://symfony.com/doc/current/components/finder.html) to scan the source directory, so
have a look at its documentation to understand the filter options.

repository: scheb/tombstone

gha_language: PHP

repo_name: scheb/tombstone


text:
# How to perform CBA+ surface alignment

Follow these steps for running cortex based alignment (CBA) in `BrainVoyager v21.4`. If you are unfamiliar with CBA, see [this introductory documentation](https://www.brainvoyager.com/bv/doc/UsersGuide/CortexBasedAlignment/CortexBasedAlignmentOfSulciAndGyri.html).

## Stage 1: Preparation for standard CBA

1. [Prepare a mesh for CBA.](https://www.brainvoyager.com/bv/doc/UsersGuide/CortexBasedAlignment/PreparingAMeshForCBA.html)

2. [Morph the mesh to a sphere.](https://www.brainvoyager.com/bv/doc/UsersGuide/CortexBasedAlignment/MorphingAReconstructedCortexHemisphereToASphere.html)

3. [Map the spherical mesh onto the standard sphere mesh.](https://www.brainvoyager.com/bv/doc/UsersGuide/CortexBasedAlignment/MappingTheStandardSphereToAMorphedSphere.html)

4. [Create multi-scale curvature maps.](https://www.brainvoyager.com/bv/doc/UsersGuide/CortexBasedAlignment/CreatingCurvatureMapsForAlignment.html)

## Stage 2: Additional preparation required for CBA+

5. Draw anatomical priors on meshes by first enabling `draw on meshes` button then holding `ctrl` + clicking on desired vertices.
    - Draw Heschl's Gyrus (HG):

    - Use `Define path-of-interest` window.

    - Draw superior temporal gyrus (STG):

    - Repeat for all anatomical priors:

All the drawn individual anatomical priors are available at:
- [Our OSF data repository](https://osf.io/4mjpn/) (see `individual_invivo_MRI_surface_data` folder).

## Stage 3: Running CBA+
Note that each set of hemispheres are run separately. Which means that we have repeated this process twice.

6. Load each hemisphere.

7. Run rigid body alignment to make sure the starting point of CBAplus is optimized. We have used the default parameters as shown in the screenshot below.

8. Run CBAplus by using the `fCBA` option and passing the anatomical priors generated in Stage 2. We have used the default parameters as shown in the screenshot below. Note that although the user interface indicates `functional constraints`, we are not using functional MRI maps. We are only leveraging this functionality available in the program for passing our `anatomical priors` as `.poi` files as an additional constraint that is used in the alignment procedure.

## Stage 4: Quality control
The quality of the results depend on two major factors (in our experience):
- The quality of the surface meshes generated in Step 1 (e.g. no holes or bridges in the initial reconstructed meshes)
- Initial state of the curvature alignments being optimized (which is the reason why we first run spherical rigid body alignment in Step 7.)
As a minor factor:
- Make sure that the anatomical priors are not very close to each other so that the smoothed representations of them are not overlapping to a high degree (the amount of smoothing is determined by the `nr. smooth. steps` parameter in fCBA section in Step 8).


text:
# Estimated Time to Completion

*Kris Kowal, published August 8, 2014.*

A promise is an object that represents a period of asynchronous work.
This is a simplified example of issuing an HTTP request in a browser, returning
a promise for the response when it has been received.

```js
function request(location) {
    return new Promise(function (resolve, reject) {
        var request = new XMLHttpRequest();
        request.open(GET, location, true);
        request.onload = request.load = function () {
            resolve(request);
        };
        request.onerror = request.error = reject;
        request.send();
    });
}
```

Between calling `request` and when the request calls `onload`, the HTTP request
may call another method, `onprogress`, multiple times as chunks of the response
body arrive asynchronously.
Although the promise represents the eventual result, the whole response, it can
also make these progress events observable.

Various promise implementations have loose support for progress
notifications.
Usually, you must call a `notify` function with an arbitrary progress value, and
the corresponding `progress` handler passed to the `then` method will receive
that value.

```js
function request(location) {
    var deferred = Promise.defer();
    var request = new XMLHttpRequest();
    request.open(GET, location, true);
    request.onload = request.load = function () {
        deferred.resolve(request.responseText);
    };
    request.onprogress = function () {
        var length = request.getResponseHeader("length");
        if (length !== null) {
            deferred.notify(request.response.length / length);
        }
    };
    request.onerror = request.error = deferred.reject;
    request.send();
    return deferred.promise;
}

request(url)
.then(function onFulfilled(response) {
}, function onRejected(error) {
}, function onProgressed(progress) {
    // <------------
})
```

The progress value is presumably a number in the interval from 0 to 1
representing how much progress has been made since the request was issued,
but the progress notification has been used to stream all manner of updates
including status messages.
Otherwise, the pattern is under-specified and conceptually flawed.
There is no meaningful way for the various operators that accept promises to
infer the progress of composite promises.

## Making progress

The next major version of Q will support an alternative to arbitrary progress
messages: estimated time to completion.
This feature is available for review in the [v2][] branch of Q but will likely
changed as the general theory of reactivity develops.

[v2]: https://github.com/kriskowal/q/tree/v2

An estimated time to completion is an *observable measurement*.
These measurements compose well based on a little knowledge of the work being
estimated.

In the most trivial case, one might have a promise for a result at an exact
time.
Such a promise can simply initialize its estimated time to completion.
The estimate will never change.

```js
function at(time) {
    return new Promise(function (resolve, reject, setEstimate) {
        setTimeout(function () {
            resolve();
        }, time - Date.now());
        setEstimate(time);
    });
}
```

## All

The Promise.all method accepts an array of promises and returns a promise for an
array with the respective values.
The estimated time to completion for the aggregate promise is, by definition,
the last of the individual estimates.
The resulting array will be available when all of the individual values are
available.
Whenever the estimate for one of these promises changes, the composite promise
should emit a new estimate.

[figure]

There are two ways to track incremental changes to the estimated time to
completion.
One is to use a heap data structure, a priority queue backed by a nearly
complete binary tree, using an array.
Such a data structure will always keep the last estimated time to completion on
top, requiring time proportional to the logarithm of the number of tracked
promises to update an estimate, `O(log n)`.

However, if instead one uses a simple array, they can find the last estimate
in time proportional to the number of input promises, `O(n)`.
Typically, these arrays are small, and this is sufficient.
But even if the array is very large, there are few cases where we need to
perform this linear search.
If an individual estimate changes, the change is only relevant if it applies to
the promise that once held the current aggregate estimate and it decreased.
If the individual promise exceeds the current estimate, it becomes the new
estimate.
In all other cases, the individual estimate changes have no affect on the
aggregate.
Typically, the probability that we will need to perform a linear search for the
new estimate is inversely proportional to the number of promises.  Thus, the
average time to update the aggregate estimate is amortized constant time,
`O(n / n)`.

I credit this epiphany to a conversation I had with Erik Bryn when we met after
Fluent 2014.

## Then

To be a useful measurement, the estimated time to completion must be composable
through the `then` method of a promise.
The then method takes an input promise, returns an output promise, and
in the relevant case, calls the fulfillment handler.
The estimated time to complete the output promise depends on the estimated time
to fulfill the input promise, plus the estimated duration of the fulfillment
handler.
Unfortunately, there are not many cases where we can divine a meaningful
estimate, but when we can, passing that duration as an argument to `then`
provides enough information to compose the output estimate.

For example, if the fulfillment handler is known to simply delay by one second,
we can pass that as an argument to `then`.

```js
return promise.then(function (value) {
    return Promise.return(value).delay(1000);
}, null, 1000)
```

In another case, the fulfillment handler might consistently require the same
amount of time, regardless of the inputs, in which case it is a simple matter of
measuring.
In other cases, we might need more sophisticated heuristics.

## Progress

One can derrive a “progress” value from the estimated time to completion, the
time that one began observing the promise, and the current time.

```
progress = (now - start) / (estimate - start)
```

However, the current time is always changing.
It is not useful for a producer to push a new measurement at an arbitrary
interval.
It is however useful for a consumer to pull (or poll) a new value on demand,
perhaps in tandem with the composition of animation frames.

If a task makes progress smoothly, the promise can produce its estimated time to
completion if it knows how much progress it has made until now from the time it
began working.

```
esimtate = start + progress * (now - start)
```

## Streams

The above formula is good for estimating the time until the termination of a
*stream* of known length.
At each time an object or chunk is produced or consumed, one can emit a new
estimated time to completion.

In the following example, we assume that `response` is an HTTP response with
`status`, `headers`, and `body`. The headers are normalized to lower-case key
names, and the body is a *promise stream*, in this case, of strings.

```js
function read(response) {
    var length = +response.headers["content-length"];
    var start = Date.now();
    var chunks = [];
    var chunksLength = 0;
    return new Promise(function (resolve, reject, setEstimate) {
        response.body
        .forEach(function (chunk) {
            chunks.push(chunk);
            chunksLength += chunk.length;
            var progress = chunksLength / length;
            var duration = Date.now() - start;
            setEstimate(start + progress * duration);
        })
        .then(function () {
            resolve(Buffer.concat(chunks));
        }, reject)
        .done();
    });
}
```

## Observing Estimates

A measurement that has a current value that can change over time is best modeled
as an *observable measurement*.
This is distinct from a promise itself which may not have a current result,
which may be a value or error, and can only resolve once.
It would be strange to use promise idioms to expose a promise’s own estimated
time to completion, just as it would be awkward to use an observable for the
result of an asynchronous function call.

For the experimental branch of Q, we can observe the estimate for a promise
using `observeEstimate`. The given callback will be informed of the current
estimate [as soon as possible][asap], and ASAP after each change.

[asap]: https://github.com/kriskowal/asap

```js
promise.observeEstimate(function (estimate) {
    component.estimate = estimate;
    component.needsDraw = true;
});
```

A pending promise can be informed of a new estimate using `setEstimate`.
As with all things promise, information flows only from the creator of the
promise to all its observers.
As such, the `setEstimate` method is the third argument of the `Promise`
initializer, and also exists on “deferred” objects.

```js
new Promise(function (resolve, reject, setEstimate) {
    setEstimate(Date.now() + 1000);
});
```

```js
var deferred = Promise.defer();
deferred.setEstimate(Date.now() + 1000);
return deferred.promise;
```

As consistent with most JavaScript interfaces, times are measured in miliseconds
since the Epoch.
An estimate of Infinity means that there is no meaningful estimate.
`observeEstimate` will always produce a number and defaults to Infinity.

The interface and behavior are subject to change as we shake-down this future
release of Q, and all [feedback][] is welcome for anyone willing to brave the
instability.

[feedback]: https://github.com/kriskowal/q


text:
# Fine-Grained Emotion Recognition

## Setup

### Data resources
Please download the following data from the given links, [EmpatheticDialogues](https://github.com/facebookresearch/EmpatheticDialogues/blob/master/LICENSE), [GoEmotions](https://github.com/google-research/google-research/tree/master/goemotions), [Affect in Tweet](https://competitions.codalab.org/competitions/17751#learn_the_details-datasets) and [NRC VAD Lexicon](https://saifmohammad.com/WebPages/nrc-vad.html)

Note: For EmpatheticDialogue dataset, please use ed_data_extract.py to transform the data before preprocessing.

### Data preprocessing

For data preprocessing, run the following command

```
python preprocess.py
```
### Running the model

For training the model, go to config.py or config_multilabel.py to set the required parameters.

The training for this work was done entirely in Google Colab due to resource requirements. Use kea_singlelabel_colab_notebook for single label setting and kea_multilabel_colab notebook for multilabel settings.

#### Alternative

Follow the below instructions to use the python scripts

```
python train.py ## for single-label settings
python train_multilabel.py ## for multi-label settings
```

## Requirements

Install the required packages mentioned in requirements.txt using pip.

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

## Credits

This application uses Open Source components. You can find the source code of their open source projects along with license information below. We acknowledge and are grateful to these developers for their contributions to open source.

1. Project: Text-Classification-Pytorch <https://github.com/prakashpandey9/Text-Classification-Pytorch>
License <https://github.com/prakashpandey9/Text-Classification-Pytorch/blob/master/LICENSE.txt>

2. Project:EmpatheticDialogues <https://github.com/facebookresearch/EmpatheticDialogues>
License <https://github.com/facebookresearch/EmpatheticDialogues/blob/master/LICENSE>

3. Project:GoEmotions <https://github.com/google-research/google-research/tree/master/goemotions>

4. Dataset:Affect in Tweets <https://competitions.codalab.org/competitions/17751#learn_the_details-datasets>

5. Project:MoEL <https://github.com/HLTCHKUST/MoEL> <br />
License <https://github.com/HLTCHKUST/MoEL/blob/master/LICENSE>

## References

* [BERT Text Classification Using Pytorch](https://towardsdatascience.com/bert-text-classification-using-pytorch-723dfb8b6b5b)


text:
# MdDocs .NET CLI tool

**Applies to:** Version 0.6 and later

## Installation

*MdDocs* is a distributed as NuGet packages.

- Prerelease builds are available on [MyGet](https://www.myget.org/feed/ap0llo-mddocs/package/nuget/Grynwald.Utilities)
- Release versions are available on [NuGet.org](https://www.nuget.org/packages/Grynwald.MdDocs)

MdDocs can be used either as .NET Core CLI tool or integrated into the project build as a set of MSBuild targets (see [MdDocs MSBuild Integration](./msbuild-integration.md)).

[![NuGet](https://img.shields.io/nuget/v/Grynwald.MdDocs.svg)](https://www.nuget.org/packages/Grynwald.MdDocs)

The package `Grynwald.MdDocs` provides MdDocs as a .NET CLI tool.
To install it, run

```ps1
dotnet tool install --global Grynwald.MdDocs
```
## Prerequisites

The `Grynwald.MdDocs` package requires the .NET 6 (or later) SDK to be installed.

## Usage

See also: [Command Line Reference](./commandline/index.md)

### API Reference

To generate API reference documentation for one or more .NET assemblies, run:

```txt
mddocs apireference --assemblies <PATH-TO-ASSEMBLY-1> <PATH-TO-ASSEMBLY-2> --outdir <OUTPUT-DIRECTORY>
```

**⚠ Note:** If the output directory already exists, all files in the output directory will be deleted.

- For an example of what the output looks like, have a look at the [demo project](./demoprojects/api/DemoProject/index.md).
- For a list of supported documentation tags, see [Supported documentation tags](./apireference/tags.md).

### Command Line Help

To generate command line help for .NET console application implemented using
the [CommandLineParser package](https://www.nuget.org/packages/CommandLineParser/),
run:

```txt
mddocs commandlinehelp --assembly <PATH-TO-ASSEMBLY> --outdir <OUTPUT-DIRECTORY>
```

**⚠ Note:** If the output directory already exists, all files in the output directory will be deleted.

For an example of what the output looks like, have a look at the [demo project](./demoprojects/commandline/index.md).

## See Also

- [MdDocs MSBuild Integration](./msbuild-integration.md)
- [Command Line Reference](./commandline/index.md)
- [Configuration](./configuration/README.md)

gha_language: C#


text:
---
layout: default
---

# 1994-09-15 - Re: thoughts on RC4

## Header Data

From: Hal<EMAIL_ADDRESS>To<EMAIL_ADDRESS>Message Hash: 7c385233b47262d5d9385cc3ea65698f475b17a7fe782c705182c022851aeae3

Message ID<EMAIL_ADDRESS>Reply To<EMAIL_ADDRESS>UTC Datetime: 1994-09-15 15:46:49 UTC

Raw Date: Thu, 15 Sep 94 08:46:49 PDT

## Raw message

```
{% raw  %}From: Hal<EMAIL_ADDRESS>Date: Thu, 15 Sep 94 08:46:49 PDT
To<EMAIL_ADDRESS>Subject: Re: thoughts on RC4
In-Reply-To<EMAIL_ADDRESS>Message-ID<EMAIL_ADDRESS>MIME-Version: 1.0
Content-Type: text/plain

<EMAIL_ADDRESS>(Perry E. Metzger) writes:

>Unlike most ciphers, RC4 doesn't seem to have any particular word
>length dependancies in its principles. That is to say, a cipher like
>IDEA has lots of magic numbers involved, but RC4 does not, which means
>that one could, in principle, extend it from being byte oriented
>stream to being word oriented stream without causing particular
>harm. (It would, of course, become incompatible, but thats not a real
>issue.) Can anyone see any reason why one could not change RC4 tO
>being a word oriented stream cipher, call it "ERC4"?

I'm not sure exactly how you would generalize it.  Right now it has a 256
entry table which holds a permutation of the values in 0..255.  A byte is
selected from this table and xor'd with the data stream.  To increase to
four bytes per entry and keep it as a permutation we would have to have 4
billion entries taking up 16 GB of memory which seems a bit much.
Altenatively we could still have 256 entries but have them four bytes
each, but then it's not clear that you keep the cryptographic properties
since you no longer have a permutation.

However a good application of Perry's suggestion would be to go to a
two-byte formulation.  You would have 64K entries of two bytes each,
holding a permutation of 0..65535, and then use the same algorithm with
the 256's replaced by 65536 and the chars replaced by shorts.  This would
retain the cryptographic properties and IMO would make many sorts of
attacks harder (at least requiring more data, probably by a factor of
256).  The main down side is that key setup takes 256 times longer, but
it shouldn't take much time to init a 64K entry table with a couple of
indexes and xor's per entry.  So on the whole it seems like a worthwhile
extension.

I wonder if the NSA would approve it?  I think it was Bill Sommerfield
who pointed out that it was a little curious that NSA approves RC4 with a
40 bit key when hardware-assisted search like the DES key cracker would
appear to be impractical.  Maybe some other parallel machine would be
suitable, though.  (But another possibility is that they can break the
cypher and the key length restriction is just cover for that.)

Trying to get a 16-bit RC4 approved for export would perhaps not work
for 40 bit keys because key setup takes 256 times longer, but key size
could be decreased to 32 bits to compensate.  OTOH maybe that is not
necessary because probably the whole array does not have to be set up
in order to tell whether a given key will work.  1/3 of the entries in
the table are fixed once they have been swapped once, so if you checked
after doing the first 20 entries, say, about 7 should have their final
values, and we can perhaps reject a key already in a known plaintext
situation just from that.  So actually the large table size may not
help against exhaustive key search.  (The mod I suggested to the key
setup would defend against this possibility, which raises the question
of whether this design aspect was chosen to allow for export approval.)

Hal

Hal

{% endraw %}
```

## Thread

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

+ Return to "[Bill Sommerfeld <sommerfeld@orchard.medford.ma.us>](/authors/bill_sommerfeld_sommerfeld_at_orchard_medford_ma_us_)"
+ Return to "[Hal <hfinney@shell.portal.com>](/authors/hal_hfinney_at_shell_portal_com_)"
+ Return to "["Ian Farquhar" <ianf@wiley.sydney.sgi.com>](/authors/ian_farquhar_ianf_at_wiley_sydney_sgi_com_)"
+ Return to "[Jim Gillogly <jim@rand.org>](/authors/jim_gillogly_jim_at_rand_org_)"
+ Return to "[Mike Johnson second login <exabyte!gedora!mikej2@uunet.uu.net>](/authors/mike_johnson_second_login_exabytegedoramikej2_at_uunet_uu_net_)"
+ Return to<EMAIL_ADDRESS>(Perry E. Metzger)](/authors/perry_at_imsi_com_perry_e_metzger_)"
+ Return to "["Perry E. Metzger" <perry@imsi.com>](/authors/perry_e_metzger_perry_at_imsi_com_)"

+ 1994-09-15 (Thu, 15 Sep 94 07:52:27 PDT) - [thoughts on RC4](/archive/1994/09/27ba39edcdada11b49cda45f7131af94abf3bca210407e7b7f323ba6466a7636) -<EMAIL_ADDRESS>(Perry E. Metzger)_
  + 1994-09-15 (Thu, 15 Sep 94 08:46:49 PDT) - Re: thoughts on RC4 - _Hal<EMAIL_ADDRESS>    + 1994-09-15 (Thu, 15 Sep 94 09:06:23 PDT) - [Re: thoughts on RC4](/archive/1994/09/1932f342aca36c800b18b34b71fa0a9b08f41b87a3e4607dd9d42a0dae94bb08) - _"Perry E. Metzger"<EMAIL_ADDRESS>    + 1994-09-15 (Thu, 15 Sep 94 10:11:53 PDT) - [Re: thoughts on RC4](/archive/1994/09/3b85882519c1cd987ec111c5f7c6206252be44250100c87e578b947e212eab15) - _Bill Sommerfeld<EMAIL_ADDRESS>      + 1994-09-15 (Thu, 15 Sep 94 15:41:47 PDT) - [Re: thoughts on RC4](/archive/1994/09/81b2d336d64b46753b6075f750b3858473f6de0eb668dc7083b65d6d7a687640) - _Mike Johnson second login<EMAIL_ADDRESS>        + 1994-09-15 (Thu, 15 Sep 94 15:50:59 PDT) - [Re: thoughts on RC4](/archive/1994/09/a5aecfbc5c040c9ee29f61ea072fba0bffd496fbc7393d1694ae3a6737f9c9d1) - _"Perry E. Metzger"<EMAIL_ADDRESS>      + 1994-09-19 (Sun, 18 Sep 94 22:37:55 PDT) - [Re: thoughts on RC4](/archive/1994/09/612be3b487680b0ce271c1e3a31f8a5b7dc99bb45747d1e467ba6012a87fbb15) - _"Ian Farquhar"<EMAIL_ADDRESS>  + 1994-09-15 (Thu, 15 Sep 94 10:02:15 PDT) - [Re: thoughts on RC4](/archive/1994/09/2c89332814649dd911ce0cd90119260c18870db57962a932dffd6e90cefd6c7a) - _Hal<EMAIL_ADDRESS>  + 1994-09-16 (Fri, 16 Sep 94 12:24:04 PDT) - [Re: thoughts on RC4](/archive/1994/09/0709cbf00fe84b2be1739c3267206344ebac75f5012fa6481dc577288bebe8d4) - _Jim Gillogly<EMAIL_ADDRESS>    + 1994-09-16 (Fri, 16 Sep 94 12:31:39 PDT) - [Re: thoughts on RC4](/archive/1994/09/112b7b7f9bb964c84b9c6b7fdbadeb116bccfa2f5c17ac4f630e38d58c692e2a) - _"Perry E. Metzger"<EMAIL_ADDRESS>


text:
* Download SDK https://www.parse.com/docs/downloads
 * Put the jar into `libs` directory. build.gradle takes care of it.
 * Add permissons
   * See: https://parse.com/apps/quickstart#parse_data/mobile/android/native/existing
 * Set the app key to Parse.com dashboard.


text:
# Sudoku Solver (Hard 37)
Write a program to solve a Sudoku puzzle by filling the empty cells.

# Solution:

Click here
Go over board with row and col variables, once you find a slot, try every
character 1..<9 and validate your choice. If it fits, adjust board and backtrack
to see if board is solved. If it is, return True, if not, change the board back.
O(k^81) time, O(k^81) space.

# Installation
Run `make` to run python and Swift files.


text:
# Octave Wagtail Styleguide

This is an internal styleguide application for Octave wagtail sites.

#### Installation

1) Add github repo dependency to pyproject.toml

```
# pyproject.toml
octave-styleguide = { git = "https://github.com/octavenz/octave-wagtail-styleguide.git", tag = "0.1.3" }
```

2) Add module to INSTALLED_APPS
```
INSTALLED_APPS = [
   'octave_styleguide',
]
```

3) Add settings
```
# Icon directory to parse for icons
OCTAVE_STYLEGUIDE_ICON_DIR = ROOT_DIR + '/frontend/icons/'

# Scss file there `$colors: ();` are configured
OCTAVE_STYLEGUIDE_COLORS_CONFIG_FILE = ROOT_DIR + '/frontend/scss/framework-config.scss'
```

4) Add styleguide menu to base.html
```
{# load the tag #}
{% load octave_styleguide_tags %}

{# render the tag before the closing body tag #}
    {% styleguide_menu %}
</body>
```

5) Load octave_styleguide.urls
```
if settings.DEBUG:
    from octave_styleguide.urls import urlpatterns as styleguide_urlpatterns

    urlpatterns += [
        url(r'', include(styleguide_urlpatterns)),
    ]
```

Styleguide will now be loaded. By default you will be able to access a page
 for  Typography, Colors and Icons.

You can add more pages by adding a template to `app/templates/styleguide/example.html`.
This will be available at `localhost:XXXX/styleguide/example`.

There's no way to add context to requests yet.

repository: octavenz/octave-wagtail-styleguide

gha_language: HTML

repo_name: octavenz/octave-wagtail-styleguide


text:
## Rule Details

This rule aims to...

The following patterns are considered errors:

```js

describe.only('tests', () => {
  ...
});

context.only('tests', () => {
  ...
});

it.only('floats', () => {
  ...
});
```

The following patterns are not warnings:

```js

describe('tests', () => {
  ...
});

```


text:
# For
Go has only one looping construct, the for loop.

The basic for loop has three components separated by semicolons:

 - the init statement: executed before the first iteration
 - the condition expression: evaluated before every iteration
 - the post statement: executed at the end of every iteration
 -
The init statement will often be a short variable declaration, and the variables declared there are visible only in the scope of the for statement.

The loop will stop iterating once the boolean condition evaluates to false.

**Note:** Unlike other languages like C, Java, or JavaScript there are no parentheses surrounding the three components of the for statement and the braces `{ }` are always required.

```go
package main

import "fmt"

func main() {
	sum := 0
	for i := 0; i < 10; i++ {
		sum += i
	}
	fmt.Println(sum)
}
```

The init and post statements are optional.

```go
package main

import "fmt"

func main() {
	sum := 1
	for ; sum < 1000; {
		sum += sum
	}
	fmt.Println(sum)
}
```

## For is Go's "while"
At that point you can drop the semicolons: C's `while` is spelled `for` in Go.

```go
package main

import "fmt"

func main() {
	sum := 1
	for sum < 1000 {
		sum += sum
	}
	fmt.Println(sum)
}
```

## Forever
If you omit the loop condition it loops forever, so an infinite loop is compactly expressed.

```go
package main

func main() {
	for {
	}
}
```

## Navigate
[<< Constants](../6-constants/README.md) | [List Of Content](../README.md) | [If/Else >>](../8-if-else/README.md)

repository: TameshkCloud/go-tutorial

repo_name: TameshkCloud/go-tutorial


text:
## astuteoRev and astuteoMix

Both Twig filters have the same configuration options. Use astuteoRev for older Blendid projects with the string appended during the build process as part of the file.

### Setting the default assets path
By default, our projects expect the production assets to be build in the <web_pub>/site-assets/ directory. To override that, create an `astuteo-toolkit.php` file in the config directory and set the "assetPath" key.

```php
<?php
    return [
        "assetPath" => "/custom-directory/",
    ];
```

### Applying manifest to file
To apply the string from the manifest file, you can use either format:

```{{ astuteoMix('/site-assets/css/app.css') }}```

or

```{{ '/site-assets/css/app.css'|astuteoMix }}```

### Custom asset path for file
On occasion, such as a multi-site project, you may want to set the path _just_ for that file. You can do that by passing an array. The first string value should be the asset path and the second value the directory, relative to the webroot.

```{{ ['/custom-assets-directory-base/css/app.css', '/custom-assets-directory-base/']|astuteoRev }}```

### Notes
- By default, we are caching the result site-wide. Currently, that is not configurable.

[back to index](../README.md)

repository: astuteo-llc/astuteo-toolkit

repo_name: astuteo-llc/astuteo-toolkit


text:
AlpixelLoggingBundle
=================

Purpose of this bundle is to offer better automation of log handler.
Mainly about Slack reporting.

### Configuration

In your AppKernel

```
new Alpixel\Bundle\LoggingBundle\AlpixelLoggingBundle(),
new Symfony\Bundle\MonologBundle\MonologBundle(),
```

In your config.yml

```
alpixel_logging:
    slack:
      token:    "my token"
      bot_name: "Error Bot"
      channel:  "alerts"
      debug: false #To activate in debug environment
```

Don't forget to remove any basic logging configuration in your config_prod and config_dev.yml

repository: alpixel/AlpixelLoggingBundle

repo_name: alpixel/AlpixelLoggingBundle


text:
# Daytripper: Hide-My-Windows Laser Tripwire

Do you always slack off on your computer and worry about getting busted?

Not anymore because Daytripper is here to save the day!

![

## Buy Daytripper on Tindie!

I did a small production run, and you can buy them directly on Tindie:

https://www.tindie.com/products/dekuNukem/daytripper

## How it works

Daytripper comes in two parts: a Transmitter (TX) and a Receiver (RX).

![Alt text](resources/photos/face_note.jpg)

Mount the TX anywhere you want. Plug RX into your computer.

When motion is detected, RX will press `Win + M` and instantly hide what you're doing.

Alternatively, it can also lock your PC or execute a custom script.

## Features

Daytripper...

* Can detect motion within 120cm (4 ft).

* Has 5Hz scan rate, works best indoors.

* Works out-of-box with Windows, compatible with all major OSs.

* Has a 40-hour battery life, rechargeable via USB-C.

* Has a 100 meter (330 ft) communication range between TX and RX, open-air.

* Comes with a magnetic mounting kit.

* See [Quick Start Guide](https://github.com/dekuNukem/daytripper/blob/master/quick_start_guide.md) and [Advanced Usage Guide](https://github.com/dekuNukem/daytripper/blob/master/advanced_usage.md) for more details.

## Getting Started | Additional Information

If you received your Daytripper in kit form, follow this to put it together:

[Kit Assembly Guide](/assembly_guide.md)

For how to use Daytripper, see this:

[Quick Start Guide](/quick_start_guide.md)

For advanced features such as custom actions and firmware updates, read this:

[Advanced Usage](/advanced_usage.md)

## FAQ

### What operating system is supported?

Daytripper works out-of-box with Windows, from XP to 10. No driver needed.

It is also compatible with anything that supports USB keyboards, such as Linux, MacOS, Android, and more.

Read [Advanced Usage Guide](/advanced_usage.md) to see how to use it on other systems.

### Can I use it for purposes other than hiding windows?

Yes. It can also lock your computer, or perform a custom action.

See [Advanced Usage Guide](/advanced_usage.md).

### What is the range of Daytripper?

The laser ToF sensor can detect motion within 120cm (4 ft).

The wireless communication range between TX and RX should be around 100 meters (330 feet) open air. Might be less in indoor environments.

### How is the battery life?

Around 40 hours, depending on the number of triggers. Rechargeable via USB Type-C connector.

## Questions or Comments?

Please feel free to [open an issue](https://github.com/dekuNukem/daytripper/issues). This is the preferred way since it helps other people too.

You can also email me at `dekunukem gmail com` for inquires.

repository: ZSIRS/daytripper

repo_name: ZSIRS/daytripper


text:
# Ember skeleton [![Build Status](https://secure.travis-ci.org/DockYard/ember-skeleton.svg?branch=master)](http://travis-ci.org/DockYard/ember-skeleton)

**[ember-skeleton is built and maintained by DockYard, contact us for expert Ember.js consulting](https://dockyard.com/ember-consulting)**.

## About ##

Show fast-loading temporary images in place of an eventual slow-loading
image.

## Browser Compatability ##

This library relies on `addEventListener` and `removeEventListener`
which is
[IE9+](https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener#Browser_compatibility)

## Building yourself ##

```bash
npm install && bower install
ember build
```

The builds will be in the `dist/` directory.

## Installing ##

`ember install ember-skeleton`

## Looking for help? ##

If it is a bug [please open an issue on GitHub](https://github.com/dockyard/ember-skeleton/issues).

## Usage ##

Use the component in your templates:

```hbs
{{skeleton-img src="/path/to/large/image.png" tmpSrc="/path/to/small/placeholder.png"}}
```

The workflow is thus:

1. The `tmpSrc` image will be loaded first
2. Once complete the `src` image will attempt to load
3. If the `src` completes successfully it will be displayed
4. If the `src` does not complete successfully the `tmpSrc` will stay
5. If an optional `errorSrc` is provided that image will be displayed in
   the even of `src` not completing successfully.

### Error Example ###

```hbs
{{skeleton-img src="/path/to/invalid/large/image.png" tmpSrc="/path/to/small/placeholder.png" errorSrc="/path/to/error/placeholder.png"}}
```

### Setting Defaults ###

If you'd like to set defaults instead of having to manually set `tmpSrc`
and `errorSrc` for each use of `{{skeleton-img}}` you can overwrite the
component in `app/components/skeleton-img.js`

```javascript
import SkeletonImg from 'ember-skeleton/components/skeleton-img';

export default SkeletonImg.extend({
  tmpSrc: "/default/path/to/placeholder.png",
  errorSrc: "/default/path/to/error/placeholder.png"
});
```

Now you can do:

```hbs
{{skeleton-img src="/path/to/large/image.png"}}
```

You can still override the defaults by passing those values into the
component from within the template.

## Styling ##

The component itself produced an `img` tag with a `skeleton-img` class.
The follow state-based classes are also available:

* `loading` used when the `src` image is still loading
* `loaded` used when `src` has successfully completed
* `load-error` used if `src` has not succesfully completed

Because the slow-loading images will likely be a different size than the
placeholders it is recommended that you normalize the `img` tag's
dimensions:

```css
.skeleton-img {
  width: 300px;
  height: 300px;
}
```

This example will ensure that the when `src` swaps our with `tmpSrc`
that there isn't any chnages in dimensions. This of course is optional
and the values should change based upon your needs.

## Defer Rendering ##

If you'd like to defer rendering you can override the `renderSrc` value
on the component. For example, you might want to change over to only
rendering the `src` once the element is in the viewport. This is easily
accomplished in combination with
[ember-in-viewport](https://github.com/dockyard/ember-in-viewport).
Override `app/components/skeleton-img.js`

```javascript
import SkeletonImg from 'ember-skeleton/components/skeleton-img';
import InViewportMixin from 'ember-in-viewport';

const {
  set
} = Ember;

export default SkeletonImg.extend(InViewportMixin, {
  renderSrc: false,
  didEnterViewport() {
    set(this, 'renderSrc', true);
  }
});
```

This is a great performance optimization for mobile applications.

## Authors ##

* [Brian Cardarella](http://twitter.com/bcardarella)

[We are very thankful for the many contributors](https://github.com/dockyard/ember-skeleton/graphs/contributors)

## Versioning ##

This library follows [Semantic Versioning](http://semver.org)

## Want to help? ##

Please do! We are always looking to improve this library. Please see our
[Contribution Guidelines](https://github.com/dockyard/ember-skeleton/blob/master/CONTRIBUTING.md)
on how to properly submit issues and pull requests.

## Legal ##

[DockYard](http://dockyard.com/ember-consulting), Inc © 2015

[@dockyard](http://twitter.com/dockyard)

[Licensed under the MIT license](http://www.opensource.org/licenses/mit-license.php)

repository: devotox/ember-skeleton

repo_name: devotox/ember-skeleton


text:
# distil-mi-ranking

**Deprecated.  Moved into `distil-primitives.`**

Feature ranking based on a mutual information between features and a selected target.  Will rank any feature column with a semantic type of `Float`, `Boolean`, `Integer` or `Categorical`, and a corresponding structural type of `int` or `float`. A DataFrame containing `(col_idx, col_name, score)` tuples for each ranked feature will be returned to the caller.  Features that could not be ranked are excluded from the returned set.

Deployment:

```shell
pip install -e<EMAIL_ADDRESS>--process-dependency-links
```

Development:

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

repository: kiminh/distil-mi-ranking

repo_name: kiminh/distil-mi-ranking


text:
# Solidus Catalog Mode

[![CircleCI](https://circleci.com/gh/afdev82/solidus_catalog_mode.svg?style=shield)](https://circleci.com/gh/afdev82/solidus_catalog_mode)
[![codecov](https://codecov.io/gh/afdev82/solidus_catalog_mode/branch/master/graph/badge.svg)](https://codecov.io/gh/afdev82/solidus_catalog_mode)

This gem adds a boolean field to the products and to the stores.
In this way you could set a single product or the complete store to be in "catalog mode".
Then in your store frontend you can use this information to disable the link to the cart,
the price and the cart form in the product page.

## Installation

Add solidus_catalog_mode to your Gemfile:

```ruby
gem 'solidus_catalog_mode'
```

Bundle your dependencies and run the installation generator:

```shell
bin/rails generate solidus_catalog_mode:install
```

## Usage

Set the flag in the product details page in the admin to enable catalog mode for the single product.
To enable the catalog mode for the entire store, just set the same flag in the store edit page.

## Dependencies

If you want to be able to set the flag for the stores in the backend, it requires the [solidus_multi_domain](https://github.com/solidusio/solidus_multi_domain) gem.

## Development

### Testing the extension

First bundle your dependencies, then run `bin/rake`. `bin/rake` will default to building the dummy
app if it does not exist, then it will run specs. The dummy app can be regenerated by using
`bin/rake extension:test_app`.

```shell
bin/rake
```

To run [Rubocop](https://github.com/bbatsov/rubocop) static code analysis run

```shell
bundle exec rubocop
```

When testing your application's integration with this extension you may use its factories.
Simply add this require statement to your spec_helper:

```ruby
require 'solidus_catalog_mode/factories'
```

### Running the sandbox

To run this extension in a sandboxed Solidus application, you can run `bin/sandbox`. The path for
the sandbox app is `./sandbox` and `bin/rails` will forward any Rails commands to
`sandbox/bin/rails`.

Here's an example:

```
$ bin/rails server
=> Booting Puma
=> Rails <IP_ADDRESS> application starting in development
* Listening on tcp://<IP_ADDRESS>:3000
Use Ctrl-C to stop
```

### Updating the changelog

Before and after releases the changelog should be updated to reflect the up-to-date status of
the project:

```shell
bin/rake changelog
git add CHANGELOG.md
git commit -m "Update the changelog"
```

### Releasing new versions

Your new extension version can be released using `gem-release` like this:

```shell
bundle exec gem bump -v 1.6.0
bin/rake changelog
git commit -a --amend
git push
bundle exec gem release
```

## License

Copyright (c) 2021 Antonio Facciolo, released under the New BSD License.


text:
---
title: 'Webinar Recap: step into the world of microservices with Node.js'
date: '2017-04-26'
icons: []
---

You've decided to embark on the journey to microservices. Cloud 66 and YLD teamed up to create a webinar about how to create microservices with Node.js and develop, test and deploy them.

It can be daunting to look at all of the work required to get things going: Node development, using micro services on your local machine using Docker, Docker infrastructure, service discovery, distributed logging, messaging - the list goes on and on.

This webinar will help you with getting started with microservices using Node.js, Docker and docker-compose.

Along the way, you'll get introduced to some of the Cloud 66 features that'll help you stay focused as you kickstart the process while avoiding many of the infrastructure tasks of a do-it-yourself approach.

Check the recording and reach out on Twitter to Daniela (Developer YLD, @sericaia) or Daniel (Developer Advocate Cloud 66, @foldingbeauty) if you have any questions.

**Webinar**

<iframe width="560" height="315" src="https://www.youtube.com/embed/JrtMT1hbeso" frameborder="0" allowfullscreen></iframe>

**Useful resources**

A list of blog post written by Cloud 66 about microservices.
http://blog.cloud66.com/tag/microservice/

A list of blog posts written by Cloud 66 about docker.
http://blog.cloud66.com/tag/docker/

Great book about microservices written by Sam Newman.
http://shop.oreilly.com/product/0636920033158.do

Istanbul, to generate HTML reports for your Node test.
https://github.com/gotwarlost/istanbul

Lab, a very nicetest runner.
https://github.com/hapijs/lab

Code, assertions library for your tests.
https://github.com/hapijs/code

RabbitMQ tutorials to get started. With lots of examples using different programming languages.
https://www.rabbitmq.com/getstarted.html

_Originally published at [blog.yld.io](https://blog.yld.io/) on April 26, 2017 by Daniela Matos de Carvalho (@sericaia on Twitter/Github)_

repository: sericaia/www

repo_name: sericaia/www