text:
---
layout: post
title: Event-driven network automation
subtitle: Using napalm-logs and Salt
bigimg: /img/engine.jpg
---

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "NewsArticle",
  "mainEntityOfPage": {
    "@type": "WebPage",
    "@id": "https://mirceaulinic.net/2017-10-19-event-driven-network-automation/"
  },
  "headline": "Event-driven network automation using napalm-logs and Salt",
  "image": [
    "https://mirceaulinic.net/img/engine.jpg"
   ],
  "datePublished": "2017-10-19T08:10:00+00:00",
  "dateModified": "2017-10-19T08:10:00+00:00",
  "author": {
    "@type": "Person",
    "name": "Mircea Ulinic"
  },
   "publisher": {
    "@type": "Organization",
    "name": "Mircea Ulinic",
    "logo": {
      "@type": "ImageObject",
      "url": "https://mirceaulinic.net/img/avatar-icon.png"
    }
  },
  "description": "Event-driven network automation using napalm-logs and Salt"
}
</script>

One of the most common misconceptions is that network automation is *only* about
configuration management. While this is indeed a very important milestone, it
is not the ultimate achievement you want for your network. We inherit most of
the methodologies from the server side, and I can tell that the network
environments are generally much more dynamic: there are *many* internal and
external events that we are aware of, but we still continue doing things
*manually*. And by manually I mean any sort of command that you execute on the
CLI - either directly on the device, or via a configuration management tool.
Make no mistake: having a configuration management tool ensures
consistency and brings plenty of benefits, but a considerable percentage of the
tasks you execute daily (or hourly) can be *fully automated*, by implementing the event-driven
network automation methodologies. With this, I don't refer only to configuration changes, but
also to those boring email notifications you need to type manually when a BGP
neighbor has been down for several days, when an interface is flapping, or checking
with the fiber provider why the optics level is still under the threshold: all
of them (and many others) can be easily automated.

Another frequent misconception is that Salt is (just) a configuration management
tool. It is that too, but among others (including cloud provisioning,
even reactors etc.), Salt is also an event-driven automation and orchestration
framework - and, in my opinion, it is the most complete.

Sources of events
-----------------

There are several sources of information in every network, some have been there
for years, but we didn't exploit their entire potential just yet.

# SNMP Traps

The SNMP traps represent one of the most commonly used source of events. Just
that they have been mainly used as notifications, while they can be used very
well to feed an event-driven framework, and trigger completely automated actions.
Unfortunately, we can still identify the following pattern: a notification comes
in, then the network engineer either applies manually a configuration change on
the CLI of the network device, or - more recently - executes a command (from a
server or the local computer) that pushes the desired configuration; then,
eventually writes an email, and it's the same email every single time, only the
interface name being different. I hope you see what's wrong here: this entire
process can be fully automated as well.

# Syslog

Syslog messages have been as well present for so many years - that's no news!
While the SNMP traps are used, at least, as notifications, syslog messages go
very often directly into the bin. Please take a moment and ask yourself three
questions: 1) Do you store the syslog messages anywhere? 2) If you do, do you
know where is that server and how to retrieve the messages? 3) Do you use them
anyhow (excluding TAC cases)?

There's plenty of useful information in these syslog messages: they can tell
you that an interface is flapping, the optics level is below the threshold,
your device is not NTP synchronised anymore, chassis alarms, or when one of
your BGP neighbors is leaking their entire routing table to you, and many
others that can be critical for your infrastructure.

# Streaming Telemetry

Streaming telemetry is the new black; as in opposite to SNMP which requires you
to fetch data every so often, the device sends notifications when it has
anything to communicate. Besides this methodology that is more efficient, you
don't receive snippets of text, but rather structured documents. The structure
of these documents is standardised as well, in the
[OpenConfig](http://www.openconfig.net/) and IETF YANG
models. The main drawback currently is that vendors such as Juniper or Cisco
support it only on very new software distributions, e.g., you need at least
Junos 15.1 (as usually, depending on the platform), or IOS-XR 6.1.1 or higher.
I am confident this is going to get better in time however!

Gabriele Gerbino wrote a very nice [blog post on Streaming Telemetry](https://projectme10.wordpress.com/2016/11/14/telemetry-streaming-on-cisco-ios-xr-and-nxos/)
that I recommend you to read.

Using napalm-logs for syslog messages
-------------------------------------

Syslog messages are simple chunks of text that represent a notification, having
different levels of severity. But here arises the eternal problem of
the networking community: the structure of the syslog messages is not
cross-platform.

Below is a syslog message from a Junos device notifying that an interface
is down:

```text
<28>Jul 20 21:45:59 edge01.bjm01 mib2d[2424]: SNMP_TRAP_LINK_DOWN: ifIndex 502,
ifAdminStatus down(2), ifOperStatus down(2), ifName xe-0/0/0
```

The same notification from a Cisco IOS-XR would be:

```text
<187>94307: gw2.acy1 LC/0/2/CPU0:Jul  7 20:16:14.834 : ifmgr[214]:
%PKT_INFRA-LINK-3-UPDOWN : Interface TenGigE0/2/0/4, changed state to Down
```

This is why my colleague [Luke Overend](https://github.com/loverend)
and I started working on a library to normalise the syslog messages, in a
vendor-agnostic way. And we soon learnt that the most suitable structures have
been already defined in the OpenConfig and IETF YANG models.

I have elaborated more on this topic in a
[NAPALM Automation blog post](https://napalm-automation.net/napalm-logs-released/).

The syslog messages can be directed straight from the device to the napalm-logs
process via UDP, or TCP, or via brokers or other systems such as Apache Kafka,
ZeroMQ etc. The resulting structured data is binary serialised, encrypted and
signed before being published over various channels including ZeroMQ, Kafka,
or RabbitMQ.

For example, napalm-logs would map the text syslog messages above into the
[openconfig-interfaces](ops.openconfig.net/branches/master/openconfig-interfaces.html)
YANG model:

```json
{
  "error": "INTERFACE_DOWN",
  "facility": 23,
  "host": "gw2.acy1",
  "ip": "<IP_ADDRESS>",
  "os": "iosxr",
  "severity": 3,
  "timestamp":<PHONE_NUMBER>,
  "yang_message": {
      "interfaces": {
          "interface": {
              "TenGigE0/2/0/4": {
                  "state": {
                      "oper_status": "DOWN"
                  }
              }
          }
      }
  },
  "yang_model": "openconfig-interfaces"
}
```

And the structure is exactly the same when receiving the notification from
a Junos device, IOS-XR or any other platform!

One of the most important details to remember is that napalm-logs continuously
listens to syslog messages as test, and continuously publishing structured
documents, where multiple clients can connect. The clients can be event-driven
frameworks such as Salt or StackStorm, or simple scripts written in any
programming language you prefer.

Importing syslog notifications into the Salt event bus
------------------------------------------------------

As mentioned in the previous paragraph, Salt can be a client for napalm-logs,
importing the structured documents into the event bus. In the Nitrogen release
(2017.7), we have integrated an Engine,
[napalm-syslog](https://docs.saltstack.com/en/latest/ref/engines/all/salt.engines.napalm_syslog.html),
for this exact purpose. It is very easy to configure, you mainly need to tell
what is the IP address and port where Salt should be listening to the messages
from napalm-logs. You can read more details under
[*The napalm-syslog Salt engine*](https://napalm-automation.net/napalm-logs-released/)
from the same NAPALM Automation blog post.

An important detail to note here is that the messages imported into the Salt
bus have a *tag*; the associated tag for the previous example is
``napalm/syslog/iosxr/INTERFACE_DOWN/gw2.acy1`` (*each tag delimiting a
namespace*), the complete event structure being:

```json
napalm/syslog/iosxr/INTERFACE_DOWN/gw2.acy1 {
  "error": "INTERFACE_DOWN",
  "facility": 23,
  "host": "gw2.acy1",
  "ip": "<IP_ADDRESS>",
  "os": "iosxr",
  "severity": 3,
  "timestamp":<PHONE_NUMBER>,
  "yang_message": {
      "interfaces": {
          "interface": {
              "TenGigE0/2/0/4": {
                  "state": {
                      "oper_status": "DOWN"
                  }
              }
          }
      }
  },
  "yang_model": "openconfig-interfaces"
}
```

The body of the event is called *data*.

Fully automated jobs
--------------------

Once everything is up and running, your network is ready to receive the
event-driven automation blessings :-)

As every event on the Salt bus has a *tag*, it is very easy to identify events
using the [Reactor system](https://docs.saltstack.com/en/latest/topics/reactor/)
(please do read the Reactor documentation).

Let's consider the following reactor configuration:

```yaml
reactor:
  - 'napalm/syslog/*/INTERFACE_DOWN/*':
    - salt://reactor/if_down_shutdown.sls
    - salt://reactor/if_down_send_mail.sls
```

The reactor tries to match the event tags against the
``napalm/syslog/*/INTERFACE_DOWN/*`` expression; under each *namespace*, we can
have either the exact string expected, or shell globbing. In this case, for
instance, ``*`` will match anything: the first one corresponds to the network
OS namespace, while the second one will match any hostname. This expression
will therefore match the ``napalm/syslog/iosxr/INTERFACE_DOWN/gw2.acy1`` tag
from the above, as well as ``napalm/syslog/junos/INTERFACE_DOWN/edge01.lyc01``,
or ``napalm/syslog/nxos/INTERFACE_DOWN/sw01.par01``; but it will not match
``napalm/syslog/iosxr/NTP_SERVER_UNREACHABLE/gw2.acy1``, for example.

When an event is matched, the reactor will invoke one more reactor SLS
descriptors. (I remind you that SLS is Jinja+YAML, by default, but extensible
to any combination of
[renderers](https://docs.saltstack.com/en/latest/ref/renderers/))

Inside these SLS files, we describe what Salt should do when the event occurs.
In this example, when there's an interface down notification, there will be
triggered two automated actions: 1) Administratively shutdown the interface
(``salt://reactor/if_down_shutdown.sls``) & 2) Send out an email
(``salt://reactor/if_down_send_mail.sls``). Both files are stored under the
Salt filesystem (hence the ``salt://``), so they are physically found under
one of the [``file_roots``](https://docs.saltstack.com/en/latest/ref/file_server/file_roots.html)
paths, e.g.,:

```yaml
file_roots:
  base:
    - /etc/salt
```

With this configuration, the file ``salt://reactor/if_down_shutdown.sls`` has
the absolute path ``/etc/salt/reactor/if_down_shutdown.sls``,
``salt://reactor/if_down_send_mail.sls`` is
``/etc/salt/reactor/if_down_send_mail.sls``, etc. The great advantage of using
the ``salt://`` URI is that you can move the entire environment without any
configuration change (except ``file_roots`` on the Master).

Let's have a look at each of these SLS files:

``/etc/salt/reactor/if_down_shutdown.sls``
{% raw %}
```yaml
shutdown_interface:
  local.net.load_template:
    - tgt: {{ data.host }}
    - kwarg:
        template_name: salt://templates/shut_interface.jinja
        interface_name: {{ data.yang_message.interfaces.interface.keys()[0] }}
```
{% endraw %}

- ``shutdown_interface`` is just a human understandable name (it can be anything);

- ``local`` is the
[reactor type](https://docs.saltstack.com/en/latest/topics/reactor/#types-of-reactions)
that will tell Salt to invoke an execution function --
[``net.load_template``](https://docs.saltstack.com/en/develop/ref/modules/all/salt.modules.napalm_network.html#salt.modules.napalm_network.load_template) in this case.

- ``data`` is the event *data*, the body of the event, so ``data.host`` will give
the information from the ``host`` field of the message.

When interpreting the Reactor SLS, Salt will firstly render the Jinja, e.g.,
when the field ``host`` is ``gw2.acy1``, the line {% raw %}``- tgt: {{ data.host }}``{% endraw %}
becomes ``- tgt: gw2.acy1``, which tells Salt to execute ``net.load_template``
on the Minion having the ID ``gw2.acy1``. (This assumes the Minion ID is the
host of the device, but the logic can be as complex as suitable for the business
case). Under ``kwarg``, we specify the arguments used to execute
``net.load_template``: ``template_name`` specifies the template source, while
``interface_name`` is the variable sent to the
``salt://templates/shut_interface.jinja`` Jinja template. To make this easier to
understand, here's the resulting YAML after Salt renders the SLS using Jinja:

```yaml
shutdown_interface:
  local.net.load_template:
    - tgt: gw2.acy1
    - kwarg:
        template_name: salt://templates/shut_interface.jinja
        interface_name: TenGigE0/2/0/4
```

Basically, the CLI equivalent of this reactor SLS is:
``$ sudo salt 'gw2.acy1' net.load_template salt://templates/shut_interface.jinja interface_name=TenGigE0/2/0/4``.

For completeness, I will provide a very minimalist example for the
``salt://templates/shut_interface.jinja`` template. Similarly, the template
can be specified using absolute path, or from the Salt filesystem via ``salt://``,
or using one of the following URI selectors: ``http://`` / ``https://``,
``ftp://``, ``s3://``, ``swift://``.

``/etc/salt/templates/shut_interface.jinja``
{% raw %}
```jinja
{%- if grains.os == 'iosxr' %}
interface {{ interface_name }}
  shutdown
{%- elif grains.os == 'junos' %}
deactivate interface {{ interface_name }};
{%- endif %}
```
{% endraw %}

The variable ``interface_name`` is sent to the template by the reactor SLS (see
under ``kwarg``).

You can learn how to write smart, cross-vendor Jinja templates reading
[this tutorial](https://docs.saltstack.com/en/develop/topics/network_automation/index.html#napalm), or from the
[Network Programmability and Automation](http://shop.oreilly.com/product/0636920042082.do),
where Jason Edelman invited me to write a chapter about Salt. Similarly, I expanded
a little on templating configuration management in Salt, in a
[previous post](https://mirceaulinic.net/2016-12-15-configuration-management/).

The second Reactor SLS invoked when an interface down notification occurs is
``salt://reactor/if_down_send_mail.sls``:

``/etc/salt/reactor/if_down_send_mail.sls``
{% raw %}
```yaml
{%- set if_name = data.yang_message.interfaces.interface.keys()[0] %}

send_email:
  local.smtp.send_msg:
    - tgt: {{ data.host }}
    - arg:
        -<EMAIL_ADDRESS>        - Interface down notification email body.
    - kwarg:
        subject: Interface {{ if_name }} is down
```
{% endraw %}

For a better understanding of the Reactor System, I highly recommend reading
[this document](https://docs.saltstack.com/en/latest/topics/reactor/) thoroughly.

After configuring these files, we can watch how Salt automatically disables the
interface, and sends out an email.

This is already a pretty ambitious goal, but, as one can easily notice, we can
achieve this very easily, in about 20-30 lines of configuration. But, as usually,
you need to know where and what to configure, which becomes a matter of reading
lots of good documentation.

What about SNMP Traps and Streaming Telemetry
------------------------------------------------

Streaming telemetry is in general straightforward and we only need to import
the data into the Salt bus. SNMP traps are generally collected into an
alert manager, e.g., [Prometheus](https://prometheus.io/), which, in general
support webhooks that can be used to inject events into the Salt bus. I will
expand on these two topics later.

Conclusions
-----------

Reading this post, I want you to remember that network automation is not just
about configuration management; every single boring task of your daily job can
be automated. My message is: there are several ways your network is trying to
communicate with you, and it sends you millions of messages every hour; don't
ignore it!

Using napalm-logs you can process and automate many internal notifications,
in a uniform and vendor agnostic way. Injecting them into the Salt event bus,
you can very easily implement the event-driven automation in your network!


text:
# gh-webhooks
A simple system for listening and responding to GitHub webhooks.

Used to create self-hosted CI and CD servers.

Comes with Python tools for interacting with the GitHub API, so you can add comments, update statuses, etc.

license: MIT

repository: MayorTechLimited/gh-webhooks

branch_name: refs/heads/main

extension: md

license_type: permissive

repo_name: MayorTechLimited/gh-webhooks


text:
# ssato.nw_backup_config

This is an example ansible role to backup configuration files on network nodes.

<!--
How to get the role ID:
ansible-galaxy info ssato.generate_kickstart | sed -nr "s/[[:blank:]]+id: ([[:digit:]]+)/\1/p"
-->
[![Build Status](https://img.shields.io/travis/ssato/ansible-role-nw-backup-config.png)](https://travis-ci.org/ssato/ansible-role-nw-backup-config) [![Ansible Galaxy](https://img.shields.io/ansible/role/43970.svg)](https://galaxy.ansible.com/ssato/nw_backup_config)

## Notes

I don't have enough network nodes and tests are very limited.

- Tested and confirmed it works: Cisco (ios), Arista (eos), Juniper (junos)
- Tested but don't confirm it works yet: F5 Big-IP (bigip)
- Not tested: FortiOS (fortios), Cisco (iosxr)

## Requirements

- Network nodes supported
- python libraries required:

  - F5 Big-IP:

    - f5-sdk
    - bigsuds

  - FortiOS:

    - pyfg
    - fortiosapi

  - Juniper:

    - ncclient

## Role Variables

see defaults/main.yml for default definitions of each variables and some examples.

## Example

see tests/main.yml for a playbook example.

## License

MIT

## Author

Satoru SATOH (<https://github.com/ssato>)

<!-- vim:sw=2:ts=2:et:
-->

repository: ssato/ansible-role-nw-backup-config

branch_name: refs/heads/master

repo_name: ssato/ansible-role-nw-backup-config


text:
# Spring Cloud - Product Catalog Microservice

Spring Boot Microservice created during Bootcamp Santander Full-Stack Developer.

## Prepare your enviroment
- Docker 20.10.7
- Docker compose 1.29.2
- Java OpenJDK 16
- Gradle
- Spring Boot 2.5.3

## Running

Run the application on your prefered IDE and keep an eye out on that information:

```bash
 .   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::                (v2.5.3)

2021-08-18 22:13:53.071  INFO 131448 --- [           main] c.s.c.p.c.ProductCatalogApplication      : Starting ProductCatalogApplication using Java 16.0.1 on DESKTOP-HOF2JLD with PID 131448 (C:\Users\ReaperClown\Documents\Desenvolvimento\_repos\spring-microservices\product-catalog\bin\main started by ReaperClown in C:\Users\ReaperClown\Documents\Desenvolvimento\_repos\spring-microservices)
2021-08-18 22:13:53.127  INFO 131448 --- [           main] c.s.c.p.c.ProductCatalogApplication      : No active profile set, falling back to default profiles: default
2021-08-18 22:13:56.654  INFO 131448 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Bootstrapping Spring Data Elasticsearch repositories in DEFAULT mode.
2021-08-18 22:13:56.848  INFO 131448 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Finished Spring Data repository scanning in 180 ms. Found 1 Elasticsearch repository interfaces.
2021-08-18 22:13:58.064  INFO 131448 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Bootstrapping Spring Data Reactive Elasticsearch repositories in DEFAULT mode.
2021-08-18 22:13:58.083  INFO 131448 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Finished Spring Data repository scanning in 15 ms. Found 0 Reactive Elasticsearch repository interfaces.
2021-08-18 22:13:59.840  INFO 131448 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8080 (http)
2021-08-18 22:13:59.908  INFO 131448 --- [           main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
2021-08-18 22:13:59.912  INFO 131448 --- [           main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.50]
2021-08-18 22:14:00.932  INFO 131448 --- [           main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
2021-08-18 22:14:00.936  INFO 131448 --- [           main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 7364 ms
2021-08-18 22:14:03.858  INFO 131448 --- [           main] o.s.d.elasticsearch.support.VersionInfo  : Version Spring Data Elasticsearch: 4.2.3
2021-08-18 22:14:03.862  INFO 131448 --- [           main] o.s.d.elasticsearch.support.VersionInfo  : Version Elasticsearch Client in build: 7.12.1
2021-08-18 22:14:03.863  INFO 131448 --- [           main] o.s.d.elasticsearch.support.VersionInfo  : Version Elasticsearch Client used: 7.12.1
2021-08-18 22:14:07.021  INFO 131448 --- [           main] o.s.b.a.e.web.EndpointLinksResolver      : Exposing 1 endpoint(s) beneath base path '/actuator'
2021-08-18 22:14:07.494  INFO 131448 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8080 (http) with context path ''
2021-08-18 22:14:07.717  INFO 131448 --- [           main] c.s.c.p.c.ProductCatalogApplication      : Started ProductCatalogApplication in 17.977 seconds (JVM running for 21.282)
```

### This is what we're looking for
```bash
Exposing 1 endpoint(s) beneath base path '/actuator'
Tomcat started on port(s): 8080 (http) with context path ''
```

### With that we can see our endpoints, with the following url
```unix
~$  curl http://localhost:8080/actuator | json_pp
```

## This is the spected return
```json
% Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                               Dload  Upload   Total   Spent    Left  Speed
100   243    0   243    0     0  13453      0 --:--:-- --:--:-- --:--:-- 14294
{
   "_links" : {
      "self" : {
         "templated" : false,
         "href" : "http://localhost:8080/actuator"
      },
      "health" : {
         "href" : "http://localhost:8080/actuator/health",
         "templated" : false
      },
      "health-path" : {
         "href" : "http://localhost:8080/actuator/health/{*path}",
         "templated" : true
      }
   }
}
```

## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

## License
[MIT](https://choosealicense.com/licenses/mit/)

repository: ReaperClown/spring-microservices

repo_name: ReaperClown/spring-microservices


text:
# Sanity Graph Import

`sanity-graph-import` is a tool for making partial migrations from one [Sanity](https://www.sanity.io) dataset or project to another. This can be useful if you only want to import particular documents and those they reference. A common use case might be "refreshing" a staging dataset from production - when the production dataset is large and would otherwise take a lot of time and bandwidth to export & import.

This script will take a selection of initial documents (provided by you as simple Sanity queries), then traverse through all documents it references, find all assets used by any of these documents, then add them to your destination dataset as a "complete" dataset with fully resolved references.

Example: Your **production** dataset has 1000's of `article` documents, each of which contain references to one or more `author` documents. For your staging dataset, you only want the first 10 articles _and_ their authors -- as well as any image & file assets these documents include.

Looking to copy an entire dataset? Use [Sanity's CLI instead](https://www.sanity.io/docs/importing-data) instead.

### Coming Soon

- Run from the command line
- Specify the depth of graph traversal (current default is 1)

# Installation

`yarn add @sanctucompu/sanity-graph-import`

# Usage

```js
// my-project/scripts/migrate.js
import { migrate } from '@sanctucompu/sanity-graph-import'
import CreateClient from '@sanity/client'

const sourceClient = CreateClient({
  projectId: 'abc123xyz',
  dataset: 'production',
})

const destinationClient = CreateClient({
  projectId: 'abc123xyz',
  dataset: 'staging',
  token: '789abc123xyz', // Required!
})

const initialQueries = [
  /* Fetch the 10 latest articles */
  {
    query: `
      *[_type == 'article']
      | order(releaseDate desc)
      | order(_createdAt desc) [0...$count]
    `,
    params: {
      count: 10,
    },
  },
  /* Fetch the homepage document */
  {
    query: `*[_type == 'homepage']`,
  },
]

async function run() {
  const config = {
    source: {
      client: sourceClient,
      initialQueries,
    },
    desitination: {
      client: destinationClient,
    },
  }

  await migrate(config)
}

run()
```

Then, run `node my-project/scripts/migrate.js`

This configuration will populate your destination dataset with:

- 10 article documents
- Every author document referenced in those articles
- The homepage document
- All assets from all of the above
- And any other documents referenced in the articles or the homepage

# API

## `migrate(config)`

**Returns**

A promise that resolve's with the final mutation results.

**`config`**: `ImportConfig`

```ts
interface ImportConfig {
  source: SourceConfig
  destination: DestinationConfig
}

type QueryParams = Record<string, any>

interface QueryArgs {
  query: string
  params?: QueryParams
}

interface SourceConfig {
  initialQueries: QueryArgs[]
  client: SanityClient
}

interface DestinationConfig {
  /* The destination client must have a write token! */
  client: SanityClient
  /**
   * The number of documents to include in a batch.
   *
   * default: 35
   *
   * If you are getting 'content-length' errors during migration,
   * set this to a lower number.
   */
  batchSize?: number
  /**
   * Set this value to true or false to skip the prompt to delete
   * all documents in the target dataset.
   *
   * default: undefined
   *
   * Leave undefined to include the prompt.
   */
  deleteData?: boolean | void
}
```

# Contributing

See [CONTRIBUTING.md](CONTRIBUTING.md)

# License

MIT

## Contributors ✨

Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):

Joseph Thomas
📖 💻 ⚠

This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!

repository: sanctuarycomputer/sanity-graph-import

gha_language: TypeScript

gha_license_id: MIT

repo_name: sanctuarycomputer/sanity-graph-import


text:
# Different Types of Parallax Website Templates
These are some templates which I learnt to build through some amazing YouTube videos

## YouTube Video Links

[**_DesignCourse_**](https://www.youtube.com/watch?v=Dxm6EwvQIl8 "DesignCourse"): This uses pure Vanilla JS and makes a scrolling effect of elements and not the whole screen

[**_Filip_**](https://www.youtube.com/watch?v=rLrLJQBG_qo "Filip"): This uses only HTML and SCSS and makes a scrolling effect for the whole screen and a 3D effect

[**_DevEd_**](https://www.youtube.com/watch?v=Nt70Ld0dJCM&t=48s "DevEd"): This uses a variety of JS libraries and makes the image scrolling effect with that fade-in thing for elements, I am yet to complete this.


text:
# About Boa Client API

The Boa Client API provides programmatic access to the Boa language and infrastructure.

# About Boa

For more information about Boa, please see the main website: https://boa.cs.iastate.edu/

repository: boalang/api

gha_language: Java

repo_name: boalang/api


text:
# command-queue

**a command queue**

[![npm status]

## example

`npm install --save @kessler/command-queue`

```js
const { CommandQueue, Command, haltCommand } = require('@kessler/command-queue')

class MyCommand extends Command {
    async execute(state) {
        await doSomething()
    }

    async undo(state) {
        await undoSomething()
    }
}

class MultiCommand extends Command {
    async execute(state, queue /*executing queue reference*/) {
        const resultOfSomething = await doSomething()
        if (!resultOfSomething) {
            return haltCommand
        }
        // returned command will execute after this command
        // same as enqueuing two commands but happens at
        // "runtime". Does not apply to undo
        return new MyCommand()
    }

    async undo(state) {
        await undoSomething()
    }
}

let queue = new CommandQueue()

queue.enqueue(new MyCommand())
// once MultiCommand is executed, another MyCommand is injected into the queue
// to be executed immediately after
queue.enqueue(new MultiCommand())
queue.enqueue(new MyCommand())
queue.enqueue(new MyCommand())

queue.on('enqueue', (command, queue) => {})
queue.on('before execute', (command, lastResult, queue) => {})
queue.on('after execute', (command, result, queue) => {})
queue.on('before undo', (command, lastResult, queue) => {})
queue.on('after undo', (command, undoResult, queue) => {})

const state = await queue.executeStep(2, { foo: 'bar' }) // execute 2 with initial state
await queue.execute(state) // execute the rest
await queue.undoStep() // undo 1
await queue.undo() // undo the rest
```

## license

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

repository: kessler/node-command-queue

gha_language: JavaScript

repo_name: kessler/node-command-queue


text:
**Aftertaste双手简谱** 和五线谱完全对应。

_Aftertaste_ 是加拿大歌手Shawn
Mendes演唱的歌曲，收录在其首张专辑《Handwritten》中。该专辑发行并以106,000张的美国首周销量在美国专辑榜空降冠军。

Shawn
Mendes的风格朴素清风，动用擅长乐器演奏，运用最素雅唱法演唱。因为信奉音乐最本真的美，所以他拒绝过度包装粉饰。每逢出镜就带来强烈清风，浮躁流行乐坛由此顿感敞亮阔达。偶像派靠气质长相跨过明星圈门槛，唱作人都是靠作品拿到通行证。

歌词下方是 _Aftertaste钢琴谱_ ，希望大家喜欢。

### Aftertaste歌词：

Re-rewind Friday night, never forget it
How you let me go
No more lies I'll be fine I know where I'm headed
Probably should've known

And now you're gonna say, "Pretty, please forgive me."
 Yeah
Bet it hurts, it gets worse, you know nobody, said it would be fair, oh

Turns out that no one can replace me
I'm permanent, you can't erase me
I'll help you remember me
One more kiss is all it takes
I'll leave you with the memory
And the aftertaste

And now there's something in your way
'Cause you threw it all to waste
And you wonder if you could take back what you did that day
And it hurts, 'cause...

Turns out that no one can replace me
I'm permanent, you can't erase me
I'll help you remember me
One more kiss is all it takes
I'll leave you with the memory
And the aftertaste

Truth is that no one can replace me
I'm permanent, you can't erase me
I'll help you remember me
One more kiss is all it takes
I'll leave you with the memory
And the aftertaste
And the aftertaste

path: /流行/Aftertaste-Shawn Mendes/README.md


text:
# How to contribute?
Go to the frontend folder and open index.html file in browser.
This is frontend of the website.
Now open this index.html in text editor and edit it and make improvements and changes.
The css file is inside the css folder of frontend folder.

Similarly the html of index.html has been divided to following parts:
- body.html
- navigation.html
- footer.html
These files are also in same folder as index.html. You can also view them in browser or edit them and make changes.

# WHAT TO FIX?
Well when you see index.html you can see 4 components.
- Navigation
- Notice section/News section
- Event section
- Footer part

Improve them as you see fit and propose those changes

gha_language: HTML


text:
---
title: Collections
---

## Collection Basics

Pulse provides "collections" as a way to easily save data. Collections are designed for data following the same structure or 'model'. So channels, posts, comments, reviews, store items etc.

::: tip NOTE: Collections extend Modules
Everything a Module can do, so can a Collection. [Read more]() about Modules in Pulse
:::

**Think of a collection like a database table.** Each collection comes with database-like methods to manipulate data. Data is "collected" which is a fancy way to say cached. The beauty of collections is that data can only be collected once, meaning if you need to modify it, there's one place to do so.

**\*In order to achieve this, data we collect must be [**normalized**](#what-is-data-normalization).\***

Collections are defined in the [Pulse library](./library.html), for the purpose of the following examples we'll refer to a collection as just `collection`, but this can be whatever you decide to name your collection(s).

Once you've defined a collection, you can begin saving data to it.

```js
collection.collect(someData);
```

To learn how to use `collect()` in detail see [collection-methods/collect()](/v2/docs/collection-methods.html#collect).

## What is data normalization?

Put simply, normalizing data is a way to ensure the data we're working with is consistent, accessible and in the structure we expect it. Normalized data is much easier and faster to work with.

In Pulse's case, collection data is stored internally in an object/keys format. Each piece of data is broken up and ingested individually using the "primary key" as a unique identifier. Arrays of primary keys called `indexes` are used to preserve ordering and the grouping of data (see [Groups](#groups)). This allows us to build a database-like environment.

Collected data can be an array of objects containing primary keys (id), or a single object with a primary key.
Here's an example using a basic `posts` dataset and the Pulse `collect()` method.

```js
// Single object
const post = {
  id: 234,
  title: 'A post!',
  // etc...
}

collect(post);

// Array of objects
const posts = [
  { id: 323, ... },
  { id: 243, ... },
  { id: 722, ... }
]

collect(posts);
```

## Primary Keys

Each data item collected by Pulse must have a unique id to that collection, we call this a "primary key", Pulse will use that primary key in indexes (see [Groups](/v2/docs/collections.html#groups)) and when using `collection.findById()` see [Collection Methods](/v2/docs/collection-methods.html#findbyid).

If your data has `id` or `_id` as a property, Pulse will use that automatically, but if not then you must define it in the collection [model](/v2/docs/collections.html#models). EG:

```js
model: {
  uuid: {
    type: String;
    primaryKey: true;
  }
}
```

In the above case, we set the primary key for this collection to `uuid`.

## Base collection

A module called "base" is automatically created using `data`, `actions`, `computed`, `routes` .etc from the root of the library. It behaves exactly the same as any other module, but found and defined on the root of the library instead.

```js
const core = new Pulse({
  data: {
    something: true
  },
  modules: {
    haha: {
      data: {
        something: false
      }
    }
  }
});

core.something; // true
core.haha.something; // false
```

From an architectural perspective, it's best to keep most logic and state out of the root in a larger application, but for a very small one it might be prefered.

Modules and collections can be found on the [context object](/v2/docs/context-object.html) by name, but base is spread to the root.

```js
someAction(context, yourParam) {
  context.myModule; // another module
  context.myCollection; // another collection

  // any properties from base;
  context.someBaseData;
  context.someBaseAction;
  // ...etc
}
```

There is a config toggle that makes `base` show up by name, set `baseModuleAlias: true` in the global [config](/v2/docs/library.html#config-options). _This was added as a backwards compatiblity feature._

## Groups

You should assign data a "group" as you collect it, this is required if you want to use collected data in React/Vue and have mutations in Pulse reactively cause component updates.

Groups are exposed on the collection namespace. (`collection.groupName`)

```js
collection.collect(somedata, 'groupName');
collection.collect(somedata, ['groupName', 'anotherGroupName']);
```

::: tip A use-case example
Lets say you have a collection named `posts` for your application, you might define a group called `feed` as that you collect into while scrolling through a feed. Now lets say a user "favorites" a post, you can now put that post into a group called `favorites` using the [`collection.put()`](/v2/docs/collection-methods.html#put) method.

Now both `feed` and `favorites` can be used by your components.
:::

### Groups are based on `indexes`

Arrays of IDs called `indexes` are created; which are simply arrays of primary keys, used to build arrays of complete data.

The raw indexes are also accessible if you need them.

```js
collection.indexes.groupName;
// returns: [1, 2, 3, 4, 5];
```

Each time an object's index changes, the related group rebuilds its data from the index. In the above case, `groupName` would be an array containing the data for primary keys 1-5.

You can modify the index directly and it will trigger the group to regenerate with the correct data.

::: warning NOTE
**You must define groups in the collection library if you want them to be exposed publicly to your components, computed and actions. Example below:**
:::

```js
collection: {
  groups: ['groupName', 'anotherGroupName'],
}
```

If necessary, groups can be created dynamically, however they will not be exposed publicly like regular groups. You can still make use of them by calling `collection.getGroup('name')`. This method can be used throughout the Pulse library, and is reactive within computed functions.

## Models

Collections allow you to define models for the data that you collect. This is great for ensuring valid data is always passed to your components. It also allows you to define data relations between collections, as shown in the next section.

Here's an example of a model:

```js
collection: {
  model: {
    id: {
      primaryKey: true,
      type: Number, // coming soon
      required: true, // coming soon
    }
  }
}
```

Data that does not fit the model requirements you define will not be collected, it will instead be saved in the Errors object as a "Data Rejection", so you can easily debug.

## `populate()`

Creating data relations between collections is easy and extremely useful using the `populate()` function in the collection model.

But why would you need to create data relations? The simple answer is keeping to our rule that data should not be repeated, but when it is needed in multiple places we should make it dependent on a single copy of that data, which when changed, causes any dependencies using that data to regenerate.

Let's say you have a `channel` and a several `posts` which have been made by that channel. In the post object you have an `owner` property, which is a channel id (the primary key). We can establish a relation between that `owner` id and the primary key in the channel collection. Now when groups or computed data is generated for the posts collection, each piece of data will include the full `channel` object.

When that channel is modified, any groups containing a post dependent on that channel will regenerate, and computed data dependent on those groups will regenerate also.

Here's a full example using the names I referenced above.

```js
collections: {
  posts: {
    model: {
      channel: {
        populate({ channels }, data) {
          return channels.findById(data.owner);
        }
      }
    }
  },
  channels: {} // etc..
}
```

That's it! It just works. Now each piece of data in the `channels` collection, when access within a group, will have a new property named `channel` with the value being the latest copy of the channel object.

The first parameter of the populate function is the [Context Object]() and the second is the current piece of data being evaluated against the model.

A situation where this proved extremely satisfying, was updating a channel avatar on the Notify app, every instance of that data changed reactively. Here's a gif of that in action.

![Gif showing reactivity using Pulse relations](https://i.imgur.com/kDjkHNx.gif 'All instances of the avatar update when the source is changed, including the related posts from a different collection.')

repository: pulse-framework/pulse

repo_name: pulse-framework/pulse


text:
# ScheduleCHOP

A TouchDesigner CHOP for scheduling events based on the systems time.

The days page lets you set days of the week you want to enable the CHOP.

The Time page lets you set the enable hour, minutes and seconds and disable hour minutes and seconds. You must set the disable value to be higher than the enable hour or the CHOP will not work. If you want to schedule something over midnight you can just use a math after to flip enable and disable.

When enabled the CHOP channel will have a value of 1. When disabled it will be 0.

license: Unlicense

repository: Richard-Burns/ScheduleCHOP

repo_name: Richard-Burns/ScheduleCHOP


text:
---
layout: project
type: project
image: images/HomePage.png
title: Warrior Jam App
permalink: projects/WarriorJam
date: 2019-18-12
labels:
  - Meteor
  - MongoDB
  - Git/Github
  - Javascript
  - HTML
  - CSS
summary: Group Final Project for ICS 314
---
### Warrior Jam App
*Home Page*

## What is Warrior Jam?
Many UH students have musical talents, but there is no easy way for them to find others with similar tastes and compatible musical abilities. Thus, they cannot experience the fun of informal jam sessions which could progress into performing musical groups.

WarriorJam is a web application that will help UH students (and staff) have their musical talents, and interests be discovered by other people with similar interests. The app will give you the opportunity to share your music content (YouTube, SoundCloud, etc.) By using our website, you can find and meet different people who have the same goals as you do. Who knows? You could be the next member of a band like Coldplay, Pink Floyd, Queen, and many more.

*Events Page*

*User Page*

## Contributions to the Project
In this project, my main objectives were to create the Landing Page, Sign-In/Sign-Out Pages, and the Navigation Menu. Other things that I felt contributed to the project were suggesting ideas on the website, identifying issues, assigning tasks on github, and assisting group members that were stuck.

## Takeaways from this Project
As a team, I feel that we have gained experience of what it's like in a working environment. For myself, I've gained valuable experience of what it's like working on a team. Overall, I feel that I put a good amount of effort into the project. What's most important is that I gained an understanding of how I can apply my knowledge of Javascript, HTML/CSS, Semantic UI React to solving real world problems.

## Where can I find this project?
To view our organization page, click [here](https://github.com/warrior-jam)


text:
# Exporting and Importing Configuration

Drush provides commands to export, transfer, and import configuration files
to and from a Drupal 8 site.  Configuration can be altered by different
methods in order to provide different behaviors in different environments;
for example, a development server might be configured slightly differently
than the production server.

This document describes how to make simple value changes to configuration
based on the environment, how to have a different set of enabled modules
in different configurations without affecting your exported configuration
values, and how to make more complex changes.

## Simple Value Changes

It is not necessary to alter the configuration system values to
make simple value changes to configuration variables, as this may be
done by the [configuration override system](https://www.drupal.org/node/1928898).

The configuration override system allows you to change configuration
values for a given instance of a site (e.g. the development server) by
setting configuration variables in the site's settings.php file.
For example, to change the name of a local development site:
```
$config['system.site']['name'] = 'Local Install of Awesome Widgets, Inc.';
```
Note that the configuration override system is a Drupal feature, not
a Drush feature. It should be the preferred method for changing
configuration values on a per-environment basis; however, it does not
work for some things, such as enabling and disabling modules.  For
configuration changes not handled by the configuration override system,
you can use Drush configuration filters.

## Ignoring Development Modules

Use the [Config Split](https://www.drupal.org/project/config_split) module to
split off development configuration in a dedicated config directory.

gha_language: PHP


text:
# PYTHON ENCRYPTION

RSA encryption made with Python for the Linux operating system.
It only works with letters from the dictionary used.

## Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

### Prerequisites

To run the project on your computer, you only need Python version 3.7.

### Installing

Start by updating the packages list and installing the prerequisites:

```
Ubuntu: sudo apt update
```
```
Ubuntu: sudo apt install software-properties-common
```

Next, add the deadsnakes PPA to your sources list:

```
Ubuntu: sudo add-apt-repository ppa:deadsnakes/ppa
```
Once the repository is enabled, install Python 3.7 with:
```
Ubuntu: sudo apt install python3.7
```
Credits: [https://linuxize.com/post/how-to-install-python-3-7-on-ubuntu-18-04/](https://linuxize.com/post/how-to-install-python-3-7-on-ubuntu-18-04/)

## Running

To run the project, you just need to run the python code:

```
Ubuntu: python3 RSA.py
```

After that, a menu will open and you can do the encryption using letters from the dictionary.

Dictionary: A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z, SPACE.

## Authors

* **Bruno Lemos** - [Profile](https://github.com/CaosMen)

See also the list of [contributors](https://github.com/CaosMen/RSA/contributors) who participated in this project.

## License

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

## Credits

[https://medium.com/@prudywsh/how-to-generate-big-prime-numbers-miller-rabin-49e6e6af32fb](https://medium.com/@prudywsh/how-to-generate-big-prime-numbers-miller-rabin-49e6e6af32fb)

repository: CaosMen/RSA

repo_name: CaosMen/RSA


text:
# interchange

*Trying a new kind of R&D Days*

We are `CODE.STΛR`: we code everything `.*`, but we also try to train our skills and try a bit of everything `.*`.

This is a project for trying out a new format of R&D Days structure, focused a bit more on the long-term.

## Project Resources

* Trello board: https://trello.com/b/dpYsMTtq
* AWS Organisation: codestarnl (https://codestarnl.signin.aws.amazon.com/console)

## Current project idea

After brainstorming for a bit, this is what we came up with. Our rationale was to find something not too complex
so that we can focus on learning, but still interesting enough to make us excited about it, with potential for
expanding upon later:

> *"Analyzing real-time road (or train) data to reactively route people optimally"*

It would look like a trajectory planner/scheduler (like Google Maps and/or 9292) but with a twist: instead of
always calculating the shortest trip, the app would take into account traffic patterns (and potentially expandable
to weather data) to spread routes outside of the usual ones (you could imagine this being a system to provide routes
to self-driving cars that have no choice but to obey).

As a result (for car travel for example), this would **reduce the average travel time** of people globally,
instead of minimizing distance, and eliminate traffic jams entirely (in an ideal world).

Since this app would have a very variable number of users depending on peak hours, it would need to be (dynamically)
scalable, and this is where we shine with our stateless reactive functional programming.

To achieve this goal we would need to make use of Kafka, reactive streams, Kubernetes, AWS, etc.

And because we are already familiar on how to do this kind of product with Scala, we will try the up-and-coming
Kotlin, which still falls in our domain and has potential with clients (we're not looking to drop Scala,
but having options is nice).

**On the front-end side**, options are still open, but as an initial proposal, to do things differently this time
we could opt not to do things in React/Angular again and explore another framework (Web Components?). And if not,
we could try not using JS/TS and instead try out Reason.

Or, we could take a radically different front-end approach, and make an Android application
(this still counts as front-end!), **also using Kotlin**. As a bonus this would mean that we could then share
knowledge between front-enders and back-enders on the language!

repository: code-star/interchange

gha_language: Kotlin

repo_name: code-star/interchange


text:
## Unreleased

## 3.1.0

-   Add wip tree-sitter syntax
-   Add break as special form
-   Add unless highlight as "keyword" color since when if in it too

## 1.2.0

-   Add generate snippet
-   Add case snippet
-   Add match snippet
-   Add seq snippet
-   Add unless snippet
-   Fix shebang snippet

## 1.1.2

-   Fix a bug in the snippets

## 1.1.0

-   Add pretty print snippet
-   Add shebang snippet
-   Fix try snippet
-   Tokenize radix number literals
-   Table and arrays highlight

## 1.0.0 - First Proper Release

-   Basic Janet highlight
-   Snippets for most used expressions/macros

repository: sogaiu/language-janet

repo_name: sogaiu/language-janet


text:
### How-to-run

To run this example with load balance you need:

1. build the image:
```
docker build -t exapmle_http .
```
2. run the builded image on random port:
```
docker run -P -d exapmle_http
```

3. repeat step 2 as many times as you need.

4. curl or open your browser in %this_node_ip%:8888 to check the things work

repository: mopga/docker-balancer

repo_name: mopga/docker-balancer


text:
# Minecraft design tool

** Note ** This is an old project I haven't touched in a long time. I'm only
publishing its source because someone asked and I somehow hadn't already.

This tool lets you setch out Minecraft design ideas in 2D with some of the
available materials in the game. It lets you save these designs to a database
so they can be shared with friends, or you export the design to JSON so you
can save it on your own computer.

You can check the version as of 2022-08-27 on [mcdesign.michd.me](https://mcdesign.michd.me/).

---

The portion for saving designs to a database is a [Sinatra](http://sinatrarb.com/) application,
backed with ActiveRecord. I'm running it with a MySQL database.

Note that in your server configuration, you must specify the following environment variables
for said database:

- `MCDESIGN_MYSQL_USER` - Username to access the database
- `MCDESIGN_MYSQL_PWD` - Password for same
- `MCDESIGN_MYSQL_DB` - Database name

It's assumed that the database runs on the same machine as the application, thus `localhost`.

If that's not the case, change it in `mcdesign.rb`.

## Contributing

Since there seems to be interest, I'm open to reviewing pull requests for adding new materials to the tool.

If doing so, please ensure that the existing numbers for materials keep working; older designs made in it will use different materials.

## Vagrant development environment

For convenience, a [vagrant](https://www.vagrantup.com/) development environment is provided.

It is set up to serve MCDesign at `mcdesign.vagrant`, with a default IP of <IP_ADDRESS>. Add this to your system's hosts file.

### SSL
To enable SSL in the development environment, install `minica` from https://github.com/jsha/minica

1. Run `minica --domains mcdesign.vagrant`
   This will create a root cert and private key in the same folder named minica.pem and a key minica-key.pem. It will also create the folder `mcdesign.vagrant` containing cert.pem and key.pem.
2. Move the `mcdesign.vagrant` folder into `vagrant-setup/`
3. Copy `minica.pem` into that same `mcdesign.vagrant/` folder
4. Install the `minica.pem` root certificate for your system or browser. If you're using Firefox:
   Preferences > Privacy & Security > Certificates > View Certificates > Authorities > Import
   Then restart Firefox.

If you don't want to use SSL, you'll have to edit vagrant-setup/mcdesign.local.conf before provisioning.

If you did the above SSL setup after provisioning the vagrant box, you'll have to restart the nginx service or the box itself.

### Virtual machine setup

1. Install [Vagrant](http://vagrantup.com) on your dev machine
2. Install [VirtualBox](https://www.virtualbox.org/) on your dev machine
3. Clone this repository
4. Open a terminal and navigate to the root folder of this repository
5. Run `vagrant up`. This one will take a while, go do something else while you wait.
6. Once finished, the script will tell you what to add to your hosts file. See "editing the hosts file"
7. Fire up your browser and navigate to mcdesign.local
8. Have fun doing some coding

repository: michd/mcdesign

repo_name: michd/mcdesign


text:
PIC24 Mikromedia HID Bootloader
===============================

### What is this repository for?

-   This repository contains the source code for a cross platform version of the
    HID Bootloader designed to work with the popular PIC24 Mikromedia boards
    featured in the book "Graphics, Touch, Sound and USB"
    (http://blog.flyingpic24.com/gtsu)

-   The project was born out of the lack of support of the Mikroelektronika HID
    Bootloader for OS X and Linux (currently available only on Windows)

-   The application is written in Python and uses only the standard "Tkinter"
    GUI library for maximum portability across OS X, Linux and Windows.

-   The application can run in command line mode as well as in GUI mode (use the
    -gui command line switch)

Dependencies:

-   Python 2.7

-   Tkinter (for the GUI)

-   HID API wrapper (pip install hidapi  ensure you have v.7.99post17 or later)

### Who do I talk to?

-   Please do not hesitate to contact me directly at<EMAIL_ADDRESS>
All contributors are welcome!


text:
# ChatApp
Just a simple Chat App using websockets in React.

## How To Setup and Run

1. Clone this repository and `cd` into it:

```
git clone https://github.com/SyedFaseehUddin/ChatApp.git
cd ChatApp
```
2. Run the command to install dependencies for both client and server:

```
npm i
```
3. Now run this command at root directory (ChatApp/) to start the server and client concurrently:

```
npm run dev
```

## URL's

Client URL :
```
http://localhost:3000/
```

## Snapshot

<img src="https://github.com/SyedFaseehUddin/ChatApp/blob/master/chatApp.PNG" height="648px" width="925px">

repository: SyedFaseehUddin/ChatApp

repo_name: SyedFaseehUddin/ChatApp


text:
# NyanCat
Puts Nyan Cat in the iOS 8 Notification Center :D

![NyanCatPreview](nyancat.gif)

### Intro
I wrote a Nyan Cat Notification Center widget for jailbroken phones a few years back, so it seemed fitting to bring it to iOS 8!

### How do I Nyan Cat?
developer.apple.com/ios

### License?
Pretty much the BSD license, just don't repackage it and call it your own please!

Also if you do make some changes, feel free to make a pull request and help make things more awesome!

### Contact Info?
Feel free to follow me on twitter: [@b3ll](https:///www.twitter.com/b3ll)!

gha_language: Objective-C


text:
python-gcm
======================
[![Build Status](https://secure.travis-ci.org/geeknam/python-gcm.png?branch=master)](http://travis-ci.org/geeknam/python-gcm)

Python client for Google Cloud Messaging for Android (GCM)

Usage
------------
RTFM [here](http://developer.android.com/guide/google/gcm/gcm.html)

Basic interaction sample, one message to one destination at a time
```python
gcm = GCM(API_KEY)
data = {'param1': 'value1', 'param2': 'value2'}

# Plaintext request, handles retry loops internally
gcm.request_plaintext(registration_id=reg_id, data=data)

# JSON request; caller should handle retry loops (see multicast below)
reg_ids = ['12', '34', '69']
gcm_response = gcm.request_json(registration_ids=reg_ids, data=data)

# Extra arguments
gcm_response = gcm.request_json(
    registration_ids=reg_ids, data=data,
    collapse_key='up_to_you', delay_while_idle=True, time_to_live=3600
)
```

Error handling
```python
# Plaintext request
reg_id = '12345'
try:
    canonical_id = gcm.request_plaintext(registration_id=reg_id, data=data)
    if canonical_id:
        # Repace reg_id with canonical_id in your database
        entry = entity.filter(registration_id=reg_id)
        entry.registration_id = canonical_id
        entry.save()
except GCMNotRegisteredException:
    # Remove this reg_id from database
    entity.filter(registration_id=reg_id).delete()
except GCMUnavailableException:
    # Resent the message
```

JSON multicast request
---------------------

For multicasting the same notification to many devices, GCM allows up to 1000 device targets at a time.
However, the results for each message are cached and provided within a result set after all message deliveries
 have been attempted.

See client_sample.py, used below via send_notification(). Results from each message are processed
by the client, and retried as necessary.

```python

ids = ['a12', 'b34', 'c56'] # real gcm registration ids are guid strings
devices_by_reg_id = dict(a12=device12, b34=device34, c56=device56) # where device<id> indicates some database record
from multicast_client_sample import send_notification
send_notification(ids, devices_by_reg_id, data)

```

Exceptions
------------
Read more on response errors [here](http://developer.android.com/guide/google/gcm/gcm.html#success)

There are two superclasses for errors:

* GCMRetriableException # the ones you can retry
* GCMNoRetryException   # the fatal ones (most)

And various concrete exceptions:

* GCMMalformedJsonException
* GCMConnectionException
* GCMAuthenticationException
* GCMTooManyRegIdsException
* GCMNoCollapseKeyException
* GCMInvalidTtlException
* GCMMissingRegistrationException
* GCMMismatchSenderIdException
* GCMNotRegisteredException
* GCMMessageTooBigException
* GCMInvalidRegistrationException
* GCMUnavailableException

repository: larham/python-gcm

repo_name: larham/python-gcm


text:
# DoodleWilly
Doodle Willy is a game for mobile devices inspired by the legend of William Tell.  William was an expert shot with the crossbow but on 18 November 1307 Tell and his young son visited Altdorf and passed by the hat, publicly refusing to bow to it, and so was arrested. Tell and his son would be executed, but he could redeem his life by shooting an apple off the head of his son, Walter, in a single attempt.  Let's help Willy not to fail in this challenge! Brake all the arrows that would hit his son and let pass the ones that go toward the apple in order to get more points, let the green ones to hit Walter and gain 1 life, break golden arrows to activate the power up of invincibility and try to protect Walter as long as you can!

## Note
This game was first released as a free Game on the Apple App store in June 2012. The project has now been adapted to Unity 5.3.4 and open sourced.
Some stats:
* ~5500 downloads after 10 days from launch
* 3rd place Top free games in the Kids category
* 14rd place Top free games in the Arcade category
* 29rd place Top free games in the Main category
* 59rd place Top application in the Main category

![AppStore](/Screenshots/AppStore.jpg?raw=true "AppStore")

-----
[Gameplay](https://youtu.be/6gLHdD3Huas)

Screenshots:

![Menu](/Screenshots/Menu.jpg?raw=true "Menu")
![Game1](/Screenshots/Game1.jpg?raw=true "Game1")
![Game2](/Screenshots/Game2.jpg?raw=true "Game2")
![Game3](/Screenshots/Game3.jpg?raw=true "Game3")
![Splashcreen](/Screenshots/SplashScreen.jpg?raw=true "SplashScreen")

repository: SirGandal/DoodleWilly

repo_name: SirGandal/DoodleWilly


text:
# Introduction
This is my vim settings on windows 7, 64bit with vim8.0 64bit. It is a backup and can be easily recovered. It is mainly configured for scientific writing with the help of [lervag/vimtex](https://github.com/lervag/vimtex) plugin. It has the following features:

* Good formatted \_vimrc file
* The plugins is managed by [junegunn/vim-plug](https://github.com/junegunn/vim-plug)
* Support color themes:solarized/molokai/phd
* Use [Ultisnips](https://github.com/SirVer/ultisnips) to do quick input of TeX
* Use [FastFold](https://github.com/Konfekt/FastFold) to support fold of TeX
* Use [vim-session](https://github.com/xolox/vim-session) to save work status
* Use [vim-shell](https://github.com/xolox/vim-shell) to toggle full-screen
* Add more quick math input by `vimtex#imaps#add_map`
* Support `XeLaTeX` compile (default)
* Support real-time preview: It will make use of `latexmk` to compile background
* Support forward/backward search (Switch between PDF/TeX source)

# Installation

To make it work, you need to install the following vim plugin or applications. I will list it one by one.

## Pre-Install

To make the installation work, we need some other applications, which is list below.

### Install vim and texlive

First of first of course we need to install [Vim](http://www.vim.org/download.php) and [texlive](https://www.tug.org/texlive/), the configuration is only make vim works more perfect when we write TeX document.

I should remark that vim provides an 64 bit version also, which can be found [here](https://github.com/vim/vim-win32-installer/releases/tag/v8.0.0003).

I also recommend to install `texlive` instead of other TeX system (e.g., MikTeX), since it works on all platforms and it more stable. By the way, you can **Uncheck the documents and source files** in the installation to reduce the total space (its about 2.15GB on my windows, I install all packages).

### Install plugin admin `vim-plug`

You can drop the `plug.vim` (under `myvim/downloads/plug.vim`) to `Vim8/vim80/autoload`. For new version or more information on how to install `vim-plug`, we refer to the plugin github host: [vim-plug](https://github.com/junegunn/vim-plug)

### Install `git`

Since `vim-plug` is work by install vim plugins through git, we need to install it first. Just have a look at [Downloading Git](https://git-scm.com/download/win)

### Install `python`

Since [UltiSnip](https://github.com/SirVer/ultisnips) need `python2` or `python3`, we need to install it. But note that: __Choose the right version__

* If you install vim 32 bit version on your 64 bit windows, then you should choose 32 bit python
* The newest version is not the best, you should check the required version by: run `:version` in vim, you will see `python27.dll` or `python35.dll`, thus we either install **Python 2.7** or **Python 3.5**, all the version can be found at [Download Python](https://www.python.org/downloads/)

## Install the Plugin

Now, we are at the point of install the vim plugin, believe me, it is quite easy after the long preparation.

### Clone the settings

We need first download the setting from github to your local vim installation directory (e.g. `D:\Vim8`), this can be done by (Please backup your local `_vimrc` first):

```bash
cd /D D:\Vim8
git clone https://github.com/vanabel/vim.git
```

You can check that the directory looks like:

```
Vim8
├── Vim8/_gvimrc
├── Vim8/_vimrc
├── Vim8/LICENSE
├── Vim8/myvim
├── Vim8/README.md
├── Vim8/vim80
└── Vim8/vimfiles
```

### Install the vim plugins

Now stat vim (there maybe some warnings or errors, since some plugin is not installed, which can be removed by check the plugin is installed or not first) and input `:PlugInstall`, all plugin will installed automatically.

## Things to do after this

I recommend to have a check of the file `_vimrc` and `_gvimrc` since it contains a lot of configurations, which I will not explain it here. After that, just enjoy the speed of input TeX.

# License

MIT License

Copyright (c) 2017 vanabel

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

 IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

repository: kozmers/vimrc

repo_name: kozmers/vimrc


text:
# Changelog

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

## [1.5.0](https://github.com/AyberkCakar/Petner-Angular/compare/v1.4.0...v1.5.0) (2021-01-16)

### Features

* added account blocking for login screen ([934ed3f](https://github.com/AyberkCakar/Petner-Angular/commit/934ed3f31f596c710ce9fc458c5e3bd922071403))
* added advert add image format check ([175d271](https://github.com/AyberkCakar/Petner-Angular/commit/175d2713d555a873d6a3c40ce700f41061c749f8))
* added comment favorite like and dislike ([fe2d732](https://github.com/AyberkCakar/Petner-Angular/commit/fe2d732d88997792a43ca6077eb5b64972448224))
* added favorite page component ([74c2c5b](https://github.com/AyberkCakar/Petner-Angular/commit/74c2c5b39d9808fba1c69608c175d3d0f3e169a2))
* added like button for comments and advert detail ([5ae516f](https://github.com/AyberkCakar/Petner-Angular/commit/5ae516fdc54da2137a03f631c3f42195d087a89a))
* completed favorite page ([2157f62](https://github.com/AyberkCakar/Petner-Angular/commit/2157f62f06dd9b75f051436371abf62286924b9d))

### Bug Fixes

* favorite page design bug ([439e1c5](https://github.com/AyberkCakar/Petner-Angular/commit/439e1c54129520a13aa52de96ad83cdc3ffffbbd))

## [1.4.0](https://github.com/AyberkCakar/Petner-Angular/compare/v1.3.0...v1.4.0) (2021-01-02)

### Features

* added password change to update user page ([a6949ed](https://github.com/AyberkCakar/Petner-Angular/commit/a6949ed257e8748d3c9bd28dd9fd4582dcf6a597))
* added password show/hide status ([434fdf8](https://github.com/AyberkCakar/Petner-Angular/commit/434fdf81b50c72185f4a0cbe8b0ec19bb8492f9a))
* added Password strength ([e370665](https://github.com/AyberkCakar/Petner-Angular/commit/e3706656b6c1bd1de36c39fbf0d976ea3bfb3422))
* added update password method ([79a6767](https://github.com/AyberkCakar/Petner-Angular/commit/79a676713c51c0550eed5e59cfba758caed4970a))
* added update password service ([a6c2585](https://github.com/AyberkCakar/Petner-Angular/commit/a6c258556bccb0049bf14fa283439782257c78eb))

### Bug Fixes

* changed custom avatar icons ([4ce16e4](https://github.com/AyberkCakar/Petner-Angular/commit/4ce16e4792fd40950e0d28f3f1e48df69b5ca499))
* fix auth guard ([d6dfa44](https://github.com/AyberkCakar/Petner-Angular/commit/d6dfa44ea125b296a31fb45616ec160615292be5))
* fix register page phone mask ([2d3e705](https://github.com/AyberkCakar/Petner-Angular/commit/2d3e705b7016912dbe5a00deb15b5014e8d7e368))
* fix register page route ([33b56c9](https://github.com/AyberkCakar/Petner-Angular/commit/33b56c9acd7891de18d87420689b1fb3f222ff23))

## [1.3.0](https://github.com/AyberkCakar/Petner-Angular/compare/v1.2.0...v1.3.0) (2020-11-09)

### Features

* added advert delete modal ([cca9e0e](https://github.com/AyberkCakar/Petner-Angular/commit/cca9e0e872a7326d3f1095c048f8d5cc68837a0a))
* added advert details page - api connection ([6bd9074](https://github.com/AyberkCakar/Petner-Angular/commit/6bd9074a18aa01e746a0a19e78db396fba839e41))
* added advert service ([265cb64](https://github.com/AyberkCakar/Petner-Angular/commit/265cb64760bdcce206dba196a16f082d87617731))
* added my advert list page ([a8b0719](https://github.com/AyberkCakar/Petner-Angular/commit/a8b0719a134a8aae11ad12a3753bce22ce09e485))
* added notifications to all page ([310921c](https://github.com/AyberkCakar/Petner-Angular/commit/310921cc01472a23d55bbab4b69a5978966a8a2f))
* update advert api connection ([6d7cb08](https://github.com/AyberkCakar/Petner-Angular/commit/6d7cb08cf44e831c7dd6301457a98a7e23ef923d))

### Bug Fixes

* check advert title length ([0b39357](https://github.com/AyberkCakar/Petner-Angular/commit/0b39357048d880baa5f8b67cfb4642c76bb87f91))
* fix  graphic bug. ([5b16e0e](https://github.com/AyberkCakar/Petner-Angular/commit/5b16e0eac94e220eecd9c93b421e6525462521ad))
* fix advert and update design ([8d77f47](https://github.com/AyberkCakar/Petner-Angular/commit/8d77f47b5bef263bc65ee817a38a2f44fd6e4ab4))
* fix advert update service ([2e6b820](https://github.com/AyberkCakar/Petner-Angular/commit/2e6b8205ff02fea4b8def4f32711997a92acf78f))
* fix udapte advert form page ([f9c639d](https://github.com/AyberkCakar/Petner-Angular/commit/f9c639d2296665b27498a9cabac7b393aecf06c0))

## [1.2.0](https://github.com/AyberkCakar/Petner-Angular/compare/v1.1.0...v1.2.0) (2020-11-04)

### Features

* added advert add api connection ([6a22e7b](https://github.com/AyberkCakar/Petner-Angular/commit/6a22e7bc442e5b1ad528da71af44f034b2196f17))
* added advert add page ([d79e78a](https://github.com/AyberkCakar/Petner-Angular/commit/d79e78ab15db09d8e38c28f4928447f56016f28b))
* added advert detail api connection ([e2a8025](https://github.com/AyberkCakar/Petner-Angular/commit/e2a80256d1375deb35d4b66cee441ce58f8deee5))
* added advert detail page ([127b81e](https://github.com/AyberkCakar/Petner-Angular/commit/127b81e128ea2ce48012c3ca6e26a2cfc924495d))
* added advert image upload ([c724b10](https://github.com/AyberkCakar/Petner-Angular/commit/c724b10765e3a7250f65f2dc460d82174dd54d80))
* added advert informations ([59cce08](https://github.com/AyberkCakar/Petner-Angular/commit/59cce080c924bd9109b55bcf8a8a0bba00c58062))
* added advert list screen ([f1e9a32](https://github.com/AyberkCakar/Petner-Angular/commit/f1e9a32f74a24f1080dc98ef8f116af3b7e1293e))
* added dashboard advert list api connection ([bc76446](https://github.com/AyberkCakar/Petner-Angular/commit/bc764461424e4d6b97210916375538329ebfa6b2))
* added dashboard advert list card design ([7f0fd23](https://github.com/AyberkCakar/Petner-Angular/commit/7f0fd233fa40a1bb1b8c666a814681e5a32e297c))
* added update advert page ([43e0a52](https://github.com/AyberkCakar/Petner-Angular/commit/43e0a5266a3d08c00e707b721718006a94ed5abe))
* advert model and save method ([50f88cf](https://github.com/AyberkCakar/Petner-Angular/commit/50f88cf43b6db627e0c5dcffe1dfdc9a0ac2af68))

### Bug Fixes

* fix add advert component ([896d062](https://github.com/AyberkCakar/Petner-Angular/commit/896d062c61e278e590f5b2675690d1bce59c9f11))
* fix advert add bug ([540d9c1](https://github.com/AyberkCakar/Petner-Angular/commit/540d9c15e428b22ae5edc20b71da650826c0175f))
* fix dashboard list data ([31912c3](https://github.com/AyberkCakar/Petner-Angular/commit/31912c3aaa8677ce17c46f5f4995f716def809a5))

## [1.1.0](https://github.com/AyberkCakar/Petner-Angular/compare/v0.0.0...v1.1.0) (2020-10-27)

### Features

* added forgotpassword alert component ([835b476](https://github.com/AyberkCakar/Petner-Angular/commit/835b476e03f9ae60afbbccee211d541d0c142d45))
* added login alert component ([147026b](https://github.com/AyberkCakar/Petner-Angular/commit/147026bb5590ceb2d06644820913af20d700ca66))
* added login and signup api connection ([1028ba0](https://github.com/AyberkCakar/Petner-Angular/commit/1028ba022eea3b55ca60f80d1422fb98ee00f584))
* added newpassword alert component ([4e441aa](https://github.com/AyberkCakar/Petner-Angular/commit/4e441aa49b5cdfffd762ce25473979cffe144987))
* added register alert component ([5ce7417](https://github.com/AyberkCakar/Petner-Angular/commit/5ce7417000c312c9f4b32b942ace2a77f75aa204))

### Bug Fixes

* dashboard Signout ([6cea630](https://github.com/AyberkCakar/Petner-Angular/commit/6cea6304c80d1b003deb622ad9e0420dee8432d0))
* forgot password pages ([a76b4fd](https://github.com/AyberkCakar/Petner-Angular/commit/a76b4fdeb916e49c4012c4fb443bec8f5faa0823))
* project infrastructure revised. ([956c4fa](https://github.com/AyberkCakar/Petner-Angular/commit/956c4faa4bf900ce411b75cb23ba612e25d210a5))

## 1.0.0 (2020-10-24)

### Features

* added blank Angular project. ([f62f992](https://github.com/AyberkCakar/Petner-Angular/commit/f62f992caeb5652145b2ae9cd1e9f51d5f0650a3))
* added forgot password pages ([388a28c](https://github.com/AyberkCakar/Petner-Angular/commit/388a28c9a7af7034f88f842e4ae5ec800f669d7b))
* added guards and services ([745fefa](https://github.com/AyberkCakar/Petner-Angular/commit/745fefa24d8afcc336ae6b65c83e638e2355e392))
* added heroku deploy serve.js ([8dea97e](https://github.com/AyberkCakar/Petner-Angular/commit/8dea97e79eb346998d1564670500ed3f10df2f8c))
* added login and signup page ([805f475](https://github.com/AyberkCakar/Petner-Angular/commit/805f475effcf9d86dbb9885775a9c6542c615995))

### Bug Fixes

* login page forgot password ([daa61f6](https://github.com/AyberkCakar/Petner-Angular/commit/daa61f69c81ae2148794ec1b6998b38673e07437))
* package.json heroku deploy ([c488534](https://github.com/AyberkCakar/Petner-Angular/commit/c48853482b33c259f96b6876ac0ff73bfd81b35f))

repository: AyberkCakar/Petner-Angular

gha_language: SCSS

repo_name: AyberkCakar/Petner-Angular


text:
This is a library for compressing and decompressing files in Sega's "Kosinski"
format (an LZSS variant). The goal is to produce a compressor that outputs data
identical to Sega's own compressor. Moduled Kosinski is also supported.

https://segaretro.org/Kosinski_compression

Included are basic frontends for a compressor, a decompressor, and a comparison
utility.

Sega's compressor had a fair few bugs, causing it to produce files with
a sub-optimal compression ratio. Lucky, none of these issues harm the integrity
of the compressed data. See `lib/kosinski-compress.c` for more info.

repository: Clownacy/accurate-kosinski

gha_language: CMake

gha_license_id: Zlib

repo_name: Clownacy/accurate-kosinski


text:
# Lifeofthegroup
### A work in progress telegram bot for selling your items

It accepts the bot owner's items for sale, it bothers everone that joins the channel to buy the items, accepts crypto for payment or sends the owner contact to the buyer. All of this is subject to change, of course.

# Usage
You should set the environment variables
```bash
TELEGRAM_OWNER
TELEGRAM_KEY
```
To the bot's owner username and api key, respectivelly.

repository: cauefcr/lifeofthegroup

repo_name: cauefcr/lifeofthegroup


text:
---
layout: default
---

# 1994-07-13 - Re: Pseudonymous ID cards?

## Header Data

From<EMAIL_ADDRESS>(Sidney Markowitz)

To<EMAIL_ADDRESS>Message Hash: e0100aba2770f5a1c296873428e8bf52349bc0c135fdff88c43c618e74e95e4f

Message ID<EMAIL_ADDRESS>Reply To: _N/A_

UTC Datetime: 1994-07-13 04:04:22 UTC

Raw Date: Tue, 12 Jul 94 21:04:22 PDT

## Raw message

```
{% raw  %}From<EMAIL_ADDRESS>(Sidney Markowitz)
Date: Tue, 12 Jul 94 21:04:22 PDT
To<EMAIL_ADDRESS>Subject: Re: Pseudonymous ID cards?
Message-ID<EMAIL_ADDRESS>MIME-Version: 1.0
Content-Type: text/plain

<EMAIL_ADDRESS>(Benjamin McLemore) wrote:
> digital IDs, insurance cards, credit cards, etc. that protect privacy

I've seen articles about that here and/or sci.crypt and places like that.
If you think in terms of cryptographic authentication of smaller pieces of
information instead of a card that can reveal all about someone, it isn't
too difficult. If a traffic cop wants proof that you have a valid driver's
license, all they really need access to is the key to verify the
authenticity of something that certifies that you have a valid driver's
license. Your card can provide that certificate without revealing any other
information about you than the fact that you are licensed to drive. The
good thing about this kind of setup is that information can be partitioned
so that only people with a reason to be authorized to get that information
would have access to it. The bad thing about this is that it still makes it
easy for the government to require that we all carry around a card that
tells everything about us and makes access to all that only a matter of
legal authorization. I don't want a society where my cryptographically
secured private information is required to be shown at every police
seatbelt/alcohol/immigrant/drug/pedophilia/sedition checkpoint.

 -- sidney<EMAIL_ADDRESS>

{% endraw %}
```

## Thread

+ Return to [July 1994](/archive/1994/07)

+ Return to<EMAIL_ADDRESS>(Sidney Markowitz)](/authors/sidney_at_taurus_apple_com_sidney_markowitz_)"
+ Return to<EMAIL_ADDRESS>(Timothy C. May)](/authors/tcmay_at_netcom_com_timothy_c_may_)"

+ 1994-07-13 (Tue, 12 Jul 94 21:04:22 PDT) - Re: Pseudonymous ID cards? -<EMAIL_ADDRESS>(Sidney Markowitz)_
  + 1994-07-13 (Tue, 12 Jul 94 21:55:53 PDT) - [Re: Pseudonymous ID cards?](/archive/1994/07/6f7d7de50ba9404f509c449b568c7f4d1096bcee3ac8528c8dba81eab274d99f) -<EMAIL_ADDRESS>(Timothy C. May)_


text:
Minimal RPC-over-Redis
======================

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

Why
---

Because using a queue system as backbone makes it easy to distribute
work between multiple RPC servers, and makes it easy to replace them
when necessary.

Goals
-----

- simple: make it easy to port
- low latency rather than guaranteed execution

Planned use
-----------

server:

    import redis_rpc

    def func1(arg1, arg2):
        return arg1 + arg2

    redis = StrictRedis.from_url(...)
    srv = redis_rpc.Server(redis, {'f1': func1, 'f2': func2, ...}, prefix)
    srv.serve()

client:

    import redis_rpc

    redis = StrictRedis.from_url(...)
    cli = redis_rpc.Client(redis, prefix)
    print(cli.call('f1', arg1=1, arg2=2))

Protocol
--------

Use JSON to encode requests and responses.

A published function is available as a Redis queue.  Send results via
single-use queues so that clients can BLPOP and receive them
immediately.

Queues:

- `{prefix}:{func}:calls`
- `{prefix}:{func}:result:{call-id}`

Call message:

    {"id": "{uuid}",  # random, client-assigned
     "ts": "{time-stamp-iso8601}",
     "kw": {"arg1": "value1",
            "arg2": ["some", "list", "of", "values"]}
    }

Arguments and results may be any JSON-encodable values, including
null/none.  This is not meant to be a framework that completely
ensures interoperability between clients and servers, it's up to the
author of request handlers to make sure exposed API will be usable for
planned clients.

Result message:

    # if successfull
    {"ts": "{time-stamp-iso8601}",
     "res": {result-value}}

    # or, if finished with an error
    {"ts": "{time-stamp-iso8601}",
     "err": "{human-readable description of the error}"}

Heartbeat
---------

The server also implements a heartbeat thread. To check if a server is online,
look for the `{prefix}:{server_kind}:{server_id}:alive` key in Redis. When the
server goes offline, its key expires.

repository: Codility/redis-rpc

gha_language: Go

repo_name: Codility/redis-rpc


text:
# slim3-json-parser

Parsing JSON response for Slim v3 REST API with CORS management - https://projects.alal.io

## Installation

Before we get started, please make sure that you have installed Slim 3 Framework. I was using [slim-born](https://github.com/HavenShen/slim-born/) from [HavenShen](https://github.com/HavenShen) for developing this module.

```shell
$ composer require malfasih/slim3-json-parser
```
or

*composer.json*
```javascript
"require": {
    "malfasih/slim3-json-parser": "@dev"
}
```

## Registering Component

```php
<?php
require __DIR__ . '/../vendor/autoload.php';
$app = new \Slim\App();
$container = $app->getContainer();

$container['json'] = function($container) {
	return new \Malfasih\Slim\JsonParser();
};
```

## Testing

Just with a single line of code, and it actually works.

```php
<?php

public function getUserData($request, $response)
{
  return $this->json->print($response, true, 'OK');
}
```


text:
![](resources/banner.png)

Istanbul is a yet simple watch face which is mainly focused on the second hand animation to provide sweeping motion. To prevent battery drain it starts to animate for a minute then returns back to 12 position within 3 seconds.

![](resources/screencast.gif)

Pebble app store link: http://apps.getpebble.com/en_US/application/562cf0d66edde43084000091

Thanks to https://github.com/pebble-examples/ks-clock-face example.

repository: jstevensog/istanbul

repo_name: jstevensog/istanbul


text:
collectivity
============

Node.js library to aggregate tweets, Facebook posts and Google News links that pertain to a list of keywords

Collectivity searches social media and the news for the keywords of your choosing.  You specify a list of keywords (as well as "since times") and collectivity scours the media realm and returns tweets, posts and news articles containing your keywords and have appeared since the time you specified.

Right now this is all the documentation I have.  To see an example of it in use, check out tests/test.js.

Both lib/twitter-search.js and lib/facebook-search.js require Twitter and Facebook app keys respectively in order to function.

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

Collectivity is dependent on the following npm modules:

async
cheerio
fbgraph
xml2js
twit

Things to do
------------

* Create NPM module
* Add more documentation
  1. regarding the objects returned by collectivity
  2. regardging how to use it
  3. regarding the keyword input object