text:
# RaLibrary Notification Script

## Run script

```sh
# install dependencies
pip install -r requirements.txt

# path to 'ralibrarynotification'
python3 "C:\GitHub\ralibrary-notification\ralibrarynotification"
```

## Run unit tests

Navigate to folder 'ralibrary-notification' and run:

```sh
python3 -m unittest discover -s tests
```

repository: CVBDL/ralibrary-notification

repo_name: CVBDL/ralibrary-notification


text:
# Boston Train Station's Passenger Flow Prediction

Using `Genetic Algorithm` to optimize `BP Neural Network`'s initial weight and threshold value.

Two kind prediction: `Whole Day prediction` and `Time Period Prediction`.

## Description

* Data Pre-Processing.ipynb: Generating input and output csv files

* MBTA_MATLAB Folder: Running in MATLAB to do prediction

## Tools

* **Neural Network Training Toolbox**

* **Sheffield Genetic Algorithms Toolbox**

* **MatLab**

* **Python Jupyter**

* **Numpy / Pandas**

* **Matplot**

* **Sklearn**

## Data

* MBTA historical passenger flow data, available in
MBTA.

* Weather (Rain, Snow, Temperature) historical data, has been uploaded in current folder.

* US Holiday Data, Week, Month...

## Input

## Output

## Design Structure

* Setting up BP Neural Network structure

* Using GA optimize initial weight and threshold

* Training and Testing BP Neural Network

## BP Neural Network Structure

## Genetic Algorithm Parameters

## Outcomes Display

#### BP NN Prediction without GA && BP NN Prediction with GA

#### BP NN & BP NN + GA Comparison

#### Prediction Error - BP NN without GA

#### Prediction Error - BP NN with GA

#### Evaluation / Performance / Training State / Error Histogram

branch_name: refs/heads/master

extension: md

license_type: permissive


text:
---
layout: post
title: "Improving Image Captioning with Conditional Generative Adversarial Nets"
date: 2018-05-18 09:31:53
categories: arXiv_CV
tags: arXiv_CV Image_Caption Adversarial Reinforcement_Learning Caption RNN
author: Chen Chen, Shuai Mu, Wanpeng Xiao, Zexiong Ye, Liesi Wu, Fuming Ma, Qi Ju
mathjax: true
---

* content
{:toc}

##### Abstract
In this paper, we propose a novel conditional generative adversarial nets based image captioning framework as an extension of traditional reinforcement learning (RL) based encoder-decoder architecture. To deal with the inconsistent evaluation problem between objective language metrics and subjective human judgements, we are inspired to design some "discriminator" networks to automatically and progressively determine whether generated caption is human described or machine generated. Two kinds of discriminator architecture (CNN and RNN based structures) are introduced since each has its own advantages. The proposed algorithm is generic so that it can enhance any existing encoder-decoder based image captioning model and we show that conventional RL training method is just a special case of our framework. Empirically, we show consistent improvements over all language evaluation metrics for different stage-of-the-art image captioning models.

##### Abstract (translated by Google)
在本文中，我们提出了一种基于传统强化学习（RL）的编码器 - 解码器架构的新型条件生成对抗网络图像字幕框架。为了处理客观语言指标与主观人类判断之间不一致的评估问题，我们鼓励设计一些“鉴别器”网络，以自动和逐步确定生成的字幕是由人类描述还是由机器生成。由于各自具有各自的优点，因此引入了两种鉴别器体系结构（基于CNN和RNN的结构）。所提出的算法是通用的，因此它可以增强任何现有的基于编码器 - 解码器的图像字幕模型，并且我们展示传统的RL训练方法仅仅是我们框架的特例。从经验上讲，我们针对不同阶段的最先进的图像字幕模型显示了所有语言评估指标的持续改进。

##### URL
[http://arxiv.org/abs/1805.07112](http://arxiv.org/abs/1805.07112)

##### PDF
[http://arxiv.org/pdf/1805.07112](http://arxiv.org/pdf/1805.07112)

license: MIT


text:
# oci-datastax
[simple](simple) is a Terraform module that will deploy DSE on OCI.  Instructions on how to use it are below.  Best practices are detailed in [this document](bestpractices.md).

[![Deploy to OCI](https://img.shields.io/badge/-Deploy%20to%20OCI-blue.svg?style=for-the-badge)](https://console.r1.oracleiaas.com/orm?configoverride=%7B%22plugins%22%3A%7B%22orm%22%3A%7B%22name%22%3A%22orm%22%2C%22path%22%3A%22%2Form%22%2C%22url%22%3A%22https%3A%2F%2Flocalhost%3A8484%22%2C%22loadMethod%22%3A0%2C%22globals%22%3A%5B%22webpackJsonpoci_resourcemanager_plugin%22%2C%22ouiUIkit%22%2C%22ouiUIkitIcons%22%5D%7D%7D%7D&qs=andyday%2Foci-datastax%2Fsimple)

## Clone the Module
Now, you'll want a local copy of this repo.  You can make that with the commands:

    git clone https://github.com/andyday/oci-datastax.git
    cd oci-datastax/simple
    ls

![](./images/01%20-%20git%20clone.png)

We now need to initialize the directory with the module in it.  This makes the module aware of the OCI provider.  You can do this by running:

    terraform init

This gives the following output:

![](./images/02%20-%20terraform%20init.png)

## Deploy
Now for the main attraction.  Let's make sure the plan looks good:

    terraform plan

That gives:

![](./images/03%20-%20terraform%20plan.png)

If that's good, we can go ahead and apply the deploy:

    terraform apply

You'll need to enter `yes` when prompted.  The apply should take about five minutes to run.  Once complete, you'll see something like this:

![](./images/04%20-%20terraform%20apply.png)

When the apply is complete, the infrastructure will be deployed, but cloud-init scripts will still be running.  Those will wrap up asynchronously.  OpsCenter and Lifecycle Manager (LCM) will probably be up five minutes after you run apply.  The cluster might take another ten minutes to build after that.  Now is a good time to get a coffee.

## Login to DataStax Lifecycle Manager (LCM)
When the `terraform apply` completed, it printed out the URLs for OpsCenter and LCM.  Let's check out LCM first.  Open a browser to the URL from the output.

![](./images/05%20-%20warning.png)

The username is `admin` and the password is whatever you specified in [variables.tf](simple/variables.tf).

![](./images/06%20-%20login.png)

In this case, the job isn't done yet.  If we drill down on clusters we can see that the nodes have been added but LCM hasn't yet SSH'd into them to install DSE.

![](./images/07%20-%20cluster.png)

Similarly, if we check out the job, we see it hasn't run yet.

![](./images/08%20-%20job.png)

Checking back a few minutes later, we see the job is complete!

![](./images/09%20-%20job%20done.png)

## Login to DataStax OpsCenter
Now that the LCM job is all done, let's take a look at OpsCenter.  Open up a browser to that URL.  It was printed as output when `terraform apply` completed.

![](./images/10%20-%20opscenter.png)

If everything ran ok, you should see a ring with the number of nodes you specified in [variables.tf](simple/variables.tf).

## View the Cluster in the Console
You can also login to the web console [here](https://console.us-phoenix-1.oraclecloud.com/a/compute/instances) to view the IaaS that is running the cluster.

![](./images/11%20-%20console.png)

## SSH to a Node
These machines are using Ubuntu 16.  The default login is ubuntu.  You can SSH into the machine with a command like this:

    ssh -i ~/.ssh/oci ubuntu@<Public IP Address>

You can debug deployments by investigating the cloud-init log file `/var/log/cloud-init-output.log`.

If you want to get started interacting with the database you can run `cqlsh` with the default user `cassandra` and whatever password you specified in [variables.tf](simple/variables.tf).  For instance:

    cqlsh -u cassandra -p admin

This gives:

![](./images/12%20-%20cqlsh.png)

## Destroy the Deployment
When you no longer need the DSE cluster, you can run this to delete the deployment:

    terraform destroy

You'll need to enter `yes` when prompted.  Once complete, you'll see something like this:

![](./images/13%20-%20terraform%20destroy.png)

repository: andyday/oci-datastax

repo_name: andyday/oci-datastax


text:
# Instagaram_stories
React Native UI Challenge #3.

Read this article: [Building a Instagram Stories in React Native.](https://medium.com/@yousefkama/building-instagram-stories-d14763682e98)

# Challenge

![Challenge](https://www.robertkatai.com/wp-content/uploads/2016/08/Instagram-Stories-.jpg)

The challenge was to build a demo of Instagrams new feature "Stories".

# Demo

To see it in action go to [Vimeo](https://vimeo.com/186306184) or [Medium](https://medium.com/@yousefkama/building-instagram-stories-d14763682e98)

# Try it out

Try it out at [Exponent](https://getexponent.com/@mastermo/instagram-stories).

# Author
Yousef Kama

# License
MIT License

branch_name: refs/heads/main


text:
# Log - a pretty basic logger.

A Go logger. Very basic. There are probably better loggers out there. Nothing much else to see here.

## What?
A basic logger which writes a variable number of delimeted strings to stderr. Used by [auth].

## Why?
Provides logging to stderr.

## How?
See [examples].

## Examples
See [examples] for a http/appengine implementations which uses log and auth. This is written for appengine standard 2nd gen, but also works as a standalone.

## Dependencies and services
None.

## Installation
If you want to run the example code, then install using
```sh
$ go get -u github.com/lidstromberg/examples
```
If you only want the log utility, then install with
```sh
$ go get -u github.com/lidstromberg/log
```

   [auth]: <https://github.com/lidstromberg/auth>
   [examples]: <https://github.com/lidstromberg/examples>

repository: lidstromberg/log

repo_name: lidstromberg/log


text:
# plane-feed

Aggregate plane routes from realtime [ads-b](http://en.wikipedia.org/wiki/Automatic_dependent_surveillance_%E2%80%93_broadcast) data generated by [dump1090](https://github.com/MalcolmRobb/dump1090).

![](http://i.imgur.com/6Y0Q0fa.png)

## install

```
git clone git@github.com:morganherlocker/plane-feed.git
cd plane-feed
npm install
```

## run

```
dump1090 | node index.js
```

This will create hourly geojson files with aggregated route data in `./out`. Each LineString has properties containing arrays of altitudes (feet) and times (HH:MM:SS) corresponding to each coordinate.

repository: morganherlocker/plane-feed

repo_name: morganherlocker/plane-feed


text:
---
layout: default
---

# 1996-01-01 - Re: Is this as insecure... (really "Fax crypto")

## Header Data

From<EMAIL_ADDRESS>(Thaddeus J. Beier)

To<EMAIL_ADDRESS>Message Hash: a4ec12c7f83ffa4fab392a9831add893732f3a3a0be515ab32139f8d1a72b3ab

Message ID<EMAIL_ADDRESS>Reply To: _N/A_

UTC Datetime: 1996-01-01 01:23:16 UTC

Raw Date: Mon, 1 Jan 1996 09:23:16 +0800

## Raw message

```
{% raw  %}From<EMAIL_ADDRESS>(Thaddeus J. Beier)
Date: Mon, 1 Jan 1996 09:23:16 +0800
To<EMAIL_ADDRESS>Subject: Re: Is this as insecure... (really "Fax crypto")
Message-ID<EMAIL_ADDRESS>MIME-Version: 1.0
Content-Type: text/plain

Shamir did a talk on fax crypto in May, 1994.  There is no reason that this
can't be completely secure, the overlays could be one-time pads.   Bill
Sommerfeld posted a description of the technique to the list after he went
to a presentation on the technique, I'll forward it to anybody that needs
a copy.

Using the same overlay multiple times, though, would make it completely
insecure.  I can't believe that they are recommending that that could
be a possibility.

thad
-- Thaddeus Beier<EMAIL_ADDRESS>   Technology Development<PHONE_NUMBER>
   Hammerhead Productions        http://www.got.net/~thad

{% endraw %}
```

## Thread

+ Return to [January 1996](/archive/1996/01)

+ Return to<EMAIL_ADDRESS>(Thaddeus J. Beier)](/authors/thad_at_hammerhead_com_thaddeus_j_beier_)"

+ 1996-01-01 (Mon, 1 Jan 1996 09:23:16 +0800) - Re: Is this as insecure... (really "Fax crypto") -<EMAIL_ADDRESS>(Thaddeus J. Beier)_

gha_license_id: MIT


text:
# Spiphis
Superfast port scanner https://joekoop.com/spiphis

Spiphis is a BASH script that scans the addresses and ports specified with no limit to the number of threads, and is therefore VERY fast.

## Features

- Very fast, limited by CPU speed
- Script-friendly output option

## Dependencies

- netcat `sudo apt install netcat`

repository: jkoop/spiphis

repo_name: jkoop/spiphis


text:
Welcome to my examination project

- I have structured the project in parts A,B,C and used subsequent subfolders, with the intention of displaying the different implementations clearly.
  Therefore the entire project will not make/clean in its entirety but individual makefiles are distributed in the given folders.

- I have presented my results in the corresponding out.txt files which i encourage you to look through.

- I have seperated the primary routines used to compile the project in two classes "Generation" and "IntervalSearch", the rest are sourched from the self written routines located under
  the corresponding numerical methods exercises or from the general library "matlib".

- Precision and convergence is ensured using the Round method from the Math clas, precision is therefore fed to the routines as integer parameter.

- Random number generation is done through a custom built random number generator, utilizing OS entropy for the seed value, and is located in the primary library "matlib".

- The Newton method is built on the self built multidimensional implementation and as such, many time a reusable vector will be constructed for which only the first entry will be used.

repository: ViktorHaldborg/PPNM

repo_name: ViktorHaldborg/PPNM


text:
# telegram-typescript-bot-template

[![Dependency Status](https://david-dm.org/<%= githubUsername %>/telegram-typescript-bot-template/status.svg)](https://david-dm.org/<%= githubUsername %>/telegram-typescript-bot-template)
[![Dev Dependency Status](https://david-dm.org/<%= githubUsername %>/telegram-typescript-bot-template/dev-status.svg)](https://david-dm.org/<%= githubUsername %>/telegram-typescript-bot-template?type=dev)

> Template for Telegram bots written in TypeScript

If you havnt written TypeScript before dont be scared about it.
It is nearly the same as JavaScript.
But it does provide more helpful informations before something is going wrong on runtime.

I learned a lot about JavaScript when getting using TypeScript.

## Install

```sh
$ npm install
```

## Start the bot

### Locally for development

Write to the @BotFather on Telegram and create your bot.
You will get a token that looks like this: `123:abc`.
Create a file `bot-token.txt` and put it in there.

The bot stores persistent data within the `persist` folder.
So also create this folder before starting it the first time.

```sh
$ mkdir persist
```

Then go ahead and start the bot

```sh
$ npm start
```

### On production

See the Dockerfile.
You can build a container from that.
But this repo isnt about containers.
For information about it take a look elsewhere.

The container is meant to be used with a secret containing your bot token: `/run/secrets/bot-token.txt`.
Alternativly you can supply it via an environment variable named `BOT_TOKEN`.

The container has one volume (`/app/persist`) which will contain persistent data your bot creates.
Make sure to explicitly use that volume (for example make sure its synced or pinned to a host in a multi node setup).

## Basic Folder structure

- `source` contains your TypeScript source files. Subfolders contain specifics about your implementation
  - `bot` for example contains files relevant for the telegram bot
    - `menu` for example contains a specific about the bot, the menu which is shown on /start
  - `magic` contains something relevant for doing magic. It is not relevant for the bot directly but used by it.
- `test` contains test files
- `locales` contains the translations of your bot. That way it can speak multiple languages.
- `dist` will contain the transpiled JavaScript files.
- `persist` will contain persistent data your bot uses. Make sure to keep that data persistent (Backups for example).

## Improve

You think something is missing?
Feel free to add it.
Then everyone can learn that even easier than before :)


text:
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [master](https://github.com/arichiardi/fonda/compare/v0.2.1...HEAD) - UNRELEASED

### Changed

- Make short-circuiting for anomalies optional. [#38](https://github.com/arichiardi/fonda/pull/38)
- Change `fonda.core/execute` signature to `(fn [config steps on-exception on-success & on-anomaly])`. [#38](https://github.com/arichiardi/fonda/pull/38)

### Added

- Resolve qualified keywords to step functions. [#32](https://github.com/arichiardi/fonda/pull/32)
- Make the name key for step optional and possibly a keyword. [#33](https://github.com/arichiardi/fonda/pull/33)
- Injector steps that dynamically add steps [#34](https://github.com/arichiardi/fonda/pull/34)
- Anomaly and exception handler maps [#40](https://github.com/arichiardi/fonda/pull/40)
- Steps names and handlers keys can be either strings or keywords [#40](https://github.com/arichiardi/fonda/pull/40)

### Removed

- No more `:log-exception`, `:log-anomaly`, `:log-success`. [#37](https://github.com/arichiardi/fonda/pull/37)

## [v0.2.1](https://github.com/arichiardi/fonda/compare/v0.0.2...v0.2.1) - 2018-02-12

### Changed

- Remove the ctx parameter to execute. [#21](https://github.com/arichiardi/fonda/pull/21)

## [v0.0.2](https://github.com/arichiardi/fonda/compare/v0.0.1...v0.0.2) - 2018-12-13

### Changed

- Add a simple test in `examples`. [#20](https://github.com/arichiardi/fonda/pull/20)
- Introduced the notion of Log Map that is a subset of the Fonda Context passed to the logger functions.
- Added the steps stack into the Fonda Context and the Log Map. [#15](https://github.com/arichiardi/fonda/pull/16)
- Loggers are no longer blocking, and their result is ignored. [#15](https://github.com/arichiardi/fonda/pull/16)
- No default loggers anymore. [#15](https://github.com/arichiardi/fonda/pull/16)
- Move the :initial-ctx to the config and rename runtime to FondaContext. [#15](https://github.com/arichiardi/fonda/pull/16)
- Eradicate set- from the code base. [#8](https://github.com/arichiardi/fonda/pull/8)

## [v0.0.1](https://github.com/arichiardi/fonda/compare/ece2cb8...v0.0.1) - 2018-11-17

### Added

- Config with `:anomaly?`, `:log-exception`, `:log-anomaly`, `:log-success`.
- Sequence of steps that can be asynchronous or synchronous.
- Steps can be Taps or Processors.
- After running the steps, the log functions are called.
- After calling the log functions, the callback functions are called.

repository: arichiardi/fonda

gha_language: Clojure

repo_name: arichiardi/fonda


text:
  Happy - Make children's day happy

  About the project   |
  Technologies   |
  Getting started   |
  License

## 🧸 About the project

This project was developed on the Next Level Week #03 event by [Rocketseat](https://rocketseat.com.br/) 🚀 💜

Happy is an application that connects people to institutional care homes to make many children's day happier

## 🚀 Technologies

Technologies that I used to develop this application

- [Node.js](https://nodejs.org/en/)
- [ReactJS](https://reactjs.org/)
- [React Native](https://reactnative.dev/)
- [TypeScript](https://www.typescriptlang.org/)
- [Expo](https://expo.io/)
- [Express](https://expressjs.com/pt-br/)
- [TypeORM](https://typeorm.io/#/)
- [Yup](https://github.com/jquense/yup)
- [Axios](https://github.com/axios/axios)
- [React Router DOM](https://reacttraining.com/react-router/)
- [React Navigation](https://reactnavigation.org/)

## 💻 Getting started

Import the `Insomnia.json` on Insomnia App or click on [Run in Insomnia](#insomniaButton) button

### Requirements

- [Node.js](https://nodejs.org/en/)
- [Yarn](https://classic.yarnpkg.com/)
- [Expo](https://expo.io/)

```bash
$ git clone https://github.com/DanielLeal98/nlw3-happy.git && cd nlw3-happy
```

**Follow the steps below**

### Backend

```bash
# Starting from the project root folder, go to backend folder
$ cd backend

# Install the dependencies
$ yarn

# Use the script to run the migrations
$ yarn typeorm migration:run

# To finish, run the api service
$ yarn dev

# Well done, project is started!
```

### Web

_Obs.: Before to continue, be sure to have the API running_

```bash
# Starting from the project root folder, go to web folder
$ cd web

# Install the dependencies
$ yarn

# Be sure the file 'src/services/api.ts' have the IP to your API

# Start the client
$ yarn start
```

### Mobile

_Obs.: Before to continue, be sure to have the API running_

```bash
# Starting from the project root folder, go to mobile folder
$ cd mobile

# Be sure the file 'src/services/api.ts' have the IP to your API

# Start the expo service and scan the QR code with Expo Client
$ yarn start
```

## 📝 License

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

Daniel Leal

Made with 💜  by Daniel Leal 👋  [See my linkedin](https://www.linkedin.com/in/danielleal98/)


text:
All times GMT.

* **alester**
    * 14:00:24: Morning!
* **hoelzro**
    * 14:02:07: morning `=)`
* **alester**
    * 14:02:38: That was close.
    * 14:02:42: I hate starting meetings late.
    * 14:03:10: I figured we'd have more!
* **hoelzro**
    * 14:03:29: yeah, me too
    * 14:03:31: `=(`
* **cjm**
    * 14:03:49: morning
* **hoelzro**
    * 14:03:52: so, what's first on the agenda?
    * 14:03:53: cjm: hi!
* **alester**
    * 14:04:20: cjm: Have we met?  The nick isn't familiar.
    * 14:04:27: and does everyone have a chekcout of ack2?
* **cjm**
    * 14:04:45: I don't think we've met in person.  I've made some contributions before
* **hoelzro**
    * 14:04:50: yup, and 2 #2 pencils!
* **alester**
    * 14:05:00: Wha'ts your name, cjm?
* **cjm**
    * 14:05:09: is ack2 a different repo, or just ack?
* **alester**
    * 14:05:16: no, new repo
    * 14:05:19: parallel to ack
* **cjm**
    * 14:05:20: Christopher J. Madsen
* **alester**
    * 14:05:33: Oh, ok, that's ringing a bell.
    * 14:05:53: [https://github.com/petdance/ack2](https://github.com/petdance/ack2)
* **cjm**
    * 14:06:16: I'm the one who rewrote the tests so test writers didn't need to mess with shell quoting rules
* **alester**
    * 14:06:34: That's goodness.
    * 14:08:05: OK, so here are my thoughts.
    * 14:08:27: First, I want to make everything clear (to the world) what the design changes about ack are.
    * 14:08:32: About ack 2.0.
    * 14:08:42: I am assuming anyone reading them will know what ack 1.x is.
    * 14:09:32: These design declarations will help anyone wanting to help, and they will also form the basis for the ack 2.0 docs that say "Here's how ack 2.0 is better than 1.x"
    * 14:10:08: These design declarations need to have copious examples
    * 14:10:25: because a picture is worth a thousand words, and an example with syntax is worth at least that.
    * 14:10:50: Second, I want to start chopping up the elephent.
    * 14:11:03: There's an old joke that says "How do you eat an elephant?  One forkful at a time."
    * 14:11:18: Right now the elephant is "Create & publish ack 2.0"
    * 14:12:08: The ideal chunk will be something where someone looking at the forkfuls and say "Oh, I could do that."
    * 14:12:41: Some of these chunks will be code.  Some will be docs.  Some might be tests.
    * 14:12:53: (cjm++ for cross-platform testing thinking)
    * 14:13:26: And the "someone" of "someone can say I can do that" includes me. `:-)`
    * 14:13:34: Because I am stymied by looking at this elephant.
    * 14:13:46: I have started writing actual code.  It's in ack2 repo
    * 14:14:15: but I'm wary of going to far without having design and future plans because I don't want to run afoul of blinders.
    * 14:14:37: So the more people that can see these design docs, the more people can say "Yeah, but what about…" before we go down a bad path.
    * 14:15:23: Oooh, another benefit of forkfuls: I'd like to be able to say "Hey, we're having an ackathon, come and hack some ack next Tuesday at 8" or whatever
* **hoelzro**
    * 14:15:36: ackathons++
* **alester**
    * 14:15:37: because clearly this "plan an online meeting" DOES get people interested.
    * 14:16:01: And if nothing else, hoelzro and I can have in-person ackathons without too much trouble.
    * 14:16:16: There's a strange amount of love that people have for ack, and they want to help.
    * 14:16:25: We just have to get it to where they CAN.
    * 14:16:39: OK, so, thoughts?
* **cjm**
    * 14:17:32: that all sounds reasonble
* **hoelzro**
    * 14:17:37: we should probably mention that most of our "design documents" are at [https://github.com/](https://github.com/petdance/ack2/tree/master/dev)[petdance](https://github.com/petdance/ack2/tree/master/dev)[/ack2/tree/master/dev](https://github.com/petdance/ack2/tree/master/dev)
* **alester**
    * 14:17:54: Well, I have others, hoelzro.
    * 14:17:59: But clearly they are not where they shoudl be.
* **hoelzro**
    * 14:18:02: although at this point, they're pretty informal, and some contain my own ramblings.
* **alester**
    * 14:18:17: ramblings++
    * 14:18:27: Ramblings can get cleaned up.
    * 14:18:55: A lot of README.md is design doc
* **alester**
    * 14:19:57: welcome, wolverian
* **wolverian**
    * 14:20:44: thanks, great to be here. `:)`
* **alester**
    * 14:20:54: Everyone pull from ack2, I renamed the file
    * 14:21:02: We are glad to have you
    * 14:21:25: Actualy, I think going through the principles line-by-line would be a good way to start
    * 14:21:29: and will help bring up questions.
    * 14:21:38: Especially because the first line is wrong.
    * 14:21:43: \* only search files of types it recognizes
    * 14:21:46: is not correct
    * 14:22:41: \* search all text files by default, although specifications of filetypes will override this.
* **zitterbewegung**
    * 14:23:48: Good day.
* **hoelzro**
    * 14:23:56: zitterbewegung: morning
* **alester**
    * 14:23:57: glad to have you zitterbewegung
* **hoelzro**
    * 14:24:00: or afternoon
* **alester**
    * 14:24:10: OK, updated: repull [https://github.com/petdance/ack2](https://github.com/petdance/ack2)
* **zitterbewegung**
    * 14:24:10: Morning for me.
* **zitterbewegung**
    * 14:25:30: Maybe a good idea would be to search through compressed items?
    * 14:25:35: I see that you have a plugin system.
* **cjm**
    * 14:25:43: [https://github.com/](https://github.com/petdance/ack2/blob/master/dev/high-level-principles.md)[petdance](https://github.com/petdance/ack2/blob/master/dev/high-level-principles.md)[/ack2/blob/master/dev/high-level-principles.md](https://github.com/petdance/ack2/blob/master/dev/high-level-principles.md)
* **alester**
    * 14:25:49: zitterbewegung: not yet
    * 14:25:53: plugins will be 2.1
    * 14:26:05: It is too much to try to wedge into 2.0
* **zitterbewegung**
    * 14:26:55: Oh ok.
* **alester**
    * 14:27:13: OK, repull.  I am done with my last minute changes, I hope. `:-)`
    * 14:27:31: Let's look at # Usage principles of ack 2.0 that stay the same
    * 14:27:42: Anything else needs to be said here?  Any problems with this?
* **zitterbewegung**
    * 14:28:43: Could you recognise languages by pattern matching if shebang matching fails or would that be too slow or inefficient?
    * 14:28:51: Like possibly a simple heuristic.
* **alester**
    * 14:28:56: Such as?
    * 14:29:10: Finding /<?php/  somewhere in the file?
* **zitterbewegung**
    * 14:29:19: Yea.
    * 14:29:35: Or for dr scheme
    * 14:29:42: [#lang](irc://irc.perl.org/#lang) scheme
    * 14:29:47: Match for the module declaration
    * 14:30:29: I would expect this to be implementable as a regex or a lookup table that would be extremely efficent.
* **alester**
    * 14:30:59: I'm going to put that in the 2.1+ potential features section.
* **zitterbewegung**
    * 14:31:01: Like O(1) or O(n) time with only matching the first kilobyte of the file.
    * 14:31:04: Ok sure
* **alester**
    * 14:31:13: because that could be a whole yak-shave right there.
    * 14:31:33: Also, the concerns about speed will be hard to sort out without having a solid 2.0 to start with.
* **zitterbewegung**
    * 14:31:43: Alright sure.
* **wolverian**
    * 14:33:18: file(1) might be useful for that kind of a thing; I think there's a CPAN module that embeds the magic db in itself, too, for working on windows.
* **alester**
    * 14:33:19: OK, changes pushed.
* **hoelzro**
    * 14:33:50: alester: what does ack does about file encodings, btw?
* **wolverian**
    * 14:33:55: in general, for me, shebang line support is enough.
* **alester**
    * 14:33:56: hoelzro: Ouch.
* **hoelzro**
    * 14:34:33: so, nothing really?
    * 14:34:36: `=/`
* **cjm**
    * 14:34:38: you don't need to say "(although this will probably be ack 2.1)" anymore
* **hoelzro**
    * 14:34:53: I mean, I don't know if that's really the job of ack...yet
* **cjm**
    * 14:34:54: since the heading now says 2.1+
* **hoelzro**
    * 14:35:10: but since you're trying to attract Windows users, that might be important
    * 14:35:23: since Windows uses UTF-16 (or is it UCS-2?) by default, I think
* **alester**
    * 14:35:36: Here's the thing: I don't know shit about encodings. `:-)`
* **hoelzro**
    * 14:35:49: alester: 2.1?
    * 14:35:56: alester: I know...a decent amount.
    * 14:36:02: not a master by any means
* **wolverian**
    * 14:36:06: hoelzro: or windows-1251.
* **alester**
    * 14:36:09: What would be in 2.1?
* **hoelzro**
    * 14:36:15: wolverian: thanks, good call
* **alester**
    * 14:36:28: Reload
    * 14:36:36: (I'm just going to say "Reload" whenever I push a change)
* **zitterbewegung**
    * 14:36:58: From my understanding the most common encodings are UTF-8 and Ascii
* **hoelzro**
    * 14:37:06: zitterbewegung: on Unix, they are
    * 14:37:13: and on the Internet
* **zitterbewegung**
    * 14:37:15: Oh yea and windows you have UTF-16
* **alester**
    * 14:37:25: I think that unless we know what we're doing, we just use the default behavior of Perl.
* **zitterbewegung**
    * 14:37:25: So I would support those as a bare minimum.
* **hoelzro**
    * 14:37:34: yes, and that brings many frown faces.
* **zitterbewegung**
    * 14:37:35: Yea default behavior of perl would be the best.
* **hoelzro**
    * 14:37:36: `=(` `=(` `=(`
* **alester**
    * 14:37:48: What should we do instead, hoelzro ?
* **hoelzro**
    * 14:37:54: isn't sure of the default behavior of Perl on Windows
    * 14:38:09: alester: the UTF-16 part brings frown faces, not Perl's default behavior
* **cjm**
    * 14:38:10: same as unix, except for :crlf
* **alester**
    * 14:38:14: oh, ok
* **hoelzro**
    * 14:38:17: hmm
    * 14:38:29: what if it's reading in a UTF-16 encoded file?
* **cjm**
    * 14:38:37: then you'd better tell it that
* **hoelzro**
    * 14:38:40: do I get 0x00 0x65 0x00 0x66, et
    * 14:38:43: that's what I thought
    * 14:39:10: well, Windows marks its UTF-16 files with a BOM, right?
* **zitterbewegung**
    * 14:39:14: Should we try to translate UTF-16 to UTF-8? I believe thats possible right?
* **alester**
    * 14:39:23: Reload: Added a note about encodings.
* **hoelzro**
    * 14:39:28: zitterbewegung: yeah, the Encode module can handle that
* **cjm**
    * 14:39:42: Windows usually uses a BOM
* **wolverian**
    * 14:39:49: why would ack need to translate \*to\* an encoding? isn't decoding them into character strings enough?
* **hoelzro**
    * 14:40:01: wolverian: that's exactly what we would d
    * 14:40:02: \*do
* **alester**
    * 14:40:04: wolverian: I don't know. Forgive me terminology. `:-)`
* **hoelzro**
    * 14:40:14: but we also need to encode when printing the results
    * 14:40:15: maybe.
* **alester**
    * 14:40:20: 2.0 can't handle encoding hoohah.
    * 14:40:32: There is far too much other goodness to deal with.
* **wolverian**
    * 14:40:36: that was mostly a reply to zitterbewegung. ah, printing results. yes, that probably needs to look at the locale. though I have no idea what windows does here.
* **alester**
    * 14:40:59: So encodings is off the table for this. </gavel>
* **hoelzro**
    * 14:41:02: alester: is encoding something I should look at for 2.0?
    * 14:41:05: oh, nvm
* **wolverian**
    * 14:41:14: alester: good call, it's a swamp
* **zitterbewegung**
    * 14:41:15: wolverian: I thought it would make things easier.
* **alester**
    * 14:41:16: see how I worded it.
* **zitterbewegung**
    * 14:41:28: wolverian: Reducing the problem to something we know. Maybe not. Anyways.
* **alester**
    * 14:41:30: \* use Perl's default file-handling as far as dealing with files of different encodings
    * 14:41:45: It's worked for 1.x. `:-)`
    * 14:42:27: OK, any other comments in the first two sections?  # Usage principles of ack 2.0 that stay the same
    * 14:42:27:  and # Continuing design principles of ack 2.0
* **cjm**
    * 14:45:12: "ignore version control directories, core dumps and other large files"
    * 14:45:12: will that be only if you install .ackrc, or will there be a built-in list?
* **alester**
    * 14:45:35: \* no hardcoded filetypes or directories
    * 14:45:35:     \* Everyone has different needs.  ack will ship with a default
    * 14:45:35:     ackrc, but without that, there will be no exclusions.
    * 14:45:42: Does that say it enough?
    * 14:46:03: Eh, it's pretty awkward.
* **cjm**
    * 14:46:31: those two seem to conflict
* **alester**
    * 14:46:35: ok
    * 14:46:38: Here's what I want to say
    * 14:46:45: EVERYTHING is based on the ackrc(s).
    * 14:46:53: There will be nothing hardcoded in ack itself.
    * 14:47:18: You should never have to patch your ack, which is what many people do now to get filetypes in.
* **cjm**
    * 14:47:25: then you should probably just delete \* ignore version control directories, core dumps and other large files
* **alester**
    * 14:47:37: Right, except that that will be the default behavior.
* **zitterbewegung**
    * 14:47:46: Maybe ignore large binary files?
* **alester**
    * 14:47:52: I guess maybe default behavior based onthe default ackrc should be in there.
* **zitterbewegung**
    * 14:48:05: Would that be good default behavior?
* **alester**
    * 14:48:07: "large" is a vague.
* **zitterbewegung**
    * 14:48:13: Oh ok.
    * 14:48:22: Large I mean larger than 1megabyte
* **alester**
    * 14:48:24: Anything that is not -T is ignored.
* **cjm**
    * 14:48:54: so "non-text" instead of "large"?
* **alester**
    * 14:48:58: yes
    * 14:49:03: but there will be other things, too.
    * 14:49:07: like \*.min.js
* **hoelzro**
    * 14:49:21: hooray!
* **alester**
    * 14:49:26: heh
* **cjm**
    * 14:50:03: except \*.min.js will be ackrc, and non-text will be ack core?
* **zitterbewegung**
    * 14:50:15: Heh I have a silly idea for 2.1. Classify files by their entropy.
* **alester**
    * 14:50:20: yes, non-text will be core
* **zitterbewegung**
    * 14:50:28: That would be a hilarious plugin.
    * 14:51:15: Like /dev/random would be 100% random
    * 14:51:21: anyways
* **alester**
    * 14:52:58: oooh
    * 14:53:04: how do we handle ackrc isntallation
* **cjm**
    * 14:54:06: It'd be nice if there's an ack --install
* **alester**
    * 14:54:14: that's a heck of an idea.
* **hoelzro**
    * 14:54:29: alester: you mean installing ackrc to /etc/ackrc or something?
* **alester**
    * 14:54:34: hoelzro: yes
* **hoelzro**
    * 14:54:36: ok
* **alester**
    * 14:54:53: cjm: That would let people do the single-file download, and then run ack --install
    * 14:55:02: I REALLY want to keep the single-file download, and that would do it.
* **zitterbewegung**
    * 14:55:39: Could we create a script that detects the user environment
* **hoelzro**
    * 14:55:44: alester: we should probably detect the case where no ackrc was found
* **zitterbewegung**
    * 14:55:47: like a boostrap function
* **alester**
    * 14:55:50: Sure
* **zitterbewegung**
    * 14:56:13: and then create the ackrc in a default directory? Or do we want to prompt for that directory?
* **alester**
    * 14:56:42: zitterbewegung: Not sure.
* **cjm**
    * 14:57:03: I don't see the point in a prompt, except for global vs. per-user
* **alester**
    * 14:57:20: I'm leaving that for later
* **cjm**
    * 14:57:20: ack needs to know where to look for it, so a custom value isn't useful
* **hoelzro**
    * 14:57:33: we could do that as a switch I'd bet
    * 14:57:43: what if there's a ~/.ackrc, but no /etc/ackrc?
* **alester**
    * 14:57:45: Remember that we will have MANY pleaces to look for ackrcs
    * 14:58:00: There will be a well-defined hierarchy.
* **zitterbewegung**
    * 14:59:11: is going to lunch
* **alester**
    * 14:59:13: Reload
* **Gimpson**
    * 14:59:21: Any possibility of multiple ackrcs in a particular location?
    * 14:59:32: So I have my js ackrs, my perl ackrc and my mason ackrc
* **alester**
    * 14:59:35: Gimpson: Didn't see you come in, welcome.
* **Gimpson**
    * 14:59:54: And don't have to cat them together, they can remain separate and upgradable.
    * 14:59:59: (and thanks)
* **alester**
    * 15:00:02: Gimpson: I'm not seeing the usecase for that.
    * 15:00:08: Oh, I see what you're saying.
    * 15:00:18:  /etc/ackrc.d/
* **Gimpson**
    * 15:00:24: Yeah, something like that.
* **alester**
    * 15:00:30: An interesting idea, but I think that'll be 2.1 if ever
* **hoelzro**
    * 15:00:32: /etc/ackrc.d++
* **alester**
    * 15:00:42: because we don't know how people will use the ackrc anywy
    * 15:00:59: I want to see the ackrc cowpaths.
    * 15:01:40: but I'm adding that to the 2.1 section.
    * 15:01:55: Gimpson: when did you come in?
    * 15:02:06: oh look, there you are, I missed it.
    * 15:02:23: Reload
* **cjm**
    * 15:02:58: for those who missed it: [https://github.com/](https://github.com/petdance/ack2/blob/master/dev/high-level-principles.md)[petdance](https://github.com/petdance/ack2/blob/master/dev/high-level-principles.md)[/ack2/blob/master/dev/high-level-principles.md](https://github.com/petdance/ack2/blob/master/dev/high-level-principles.md)
* **alester**
    * 15:03:18: So let's leave that for now, and I want to start thinking for forkfuls.
    * 15:03:31: [https://github.com/petdance/ack2/blob/master/dev/forkfuls.md](https://github.com/petdance/ack2/blob/master/dev/forkfuls.md)
* **Gimpson**
    * 15:03:54: I was a bit late, came in around 7:30
    * 15:04:01: er start:30
* **alester**
    * 15:04:33: Sorry for the earliness.  hoelzro and I are Central, so we're already awake. `:-)`
    * 15:04:44: OH
    * 15:04:51: EVERYTHING has to be specified via command-line
    * 15:05:12: Nothing can be in the ackrc files except for command-line switches
    * 15:05:53: You have to be able to do everything you want via the command-line.
    * 15:08:10: Scale of 1-10: How familiar are you all with the ack 1.x source code & tree?
    * 15:08:18: Me: 9
* **Gimpson**
    * 15:08:33: Me: 5
* **cjm**
    * 15:08:43: Me: ~4
* **wolverian**
    * 15:08:48: 1
* **hoelzro**
    * 15:09:06: 2
* **alester**
    * 15:09:25: ok
    * 15:10:31: OK, look at forkfuls, please
    * 15:10:39: What sorts of high-level stuff do we need to do?
    * 15:11:16: The ackrc handling is going to have to be VERY well defined.
    * 15:11:30: because we have to get it right the first time.
    * 15:11:53: I really don't want to say in 2.1 "Oh, btw, we decided that the global ackrc now is secondary to ..."
    * 15:12:03: or whatever.  Because tat will screw up a lot of people.
* **hoelzro**
    * 15:12:23: alester: I wouldn't mind taking a look at the ackrc location stuff
    * 15:12:43: but I'd need some external help to make sure I don't succumb to my own personal bias.
* **alester**
    * 15:12:50: ok
    * 15:13:07: You're talking about defining the rules, right?
    * 15:13:12: of where we find them?
* **Gimpson**
    * 15:13:12: alester: Are you looking for more TODOs for forkfuls, or wanting to start defining those rules now?
* **alester**
    * 15:13:22: No, don't want to define rules now.
* **hoelzro**
    * 15:13:39: alester: well, that and writing the code
* **alester**
    * 15:13:57: hoelzro: That's fine too
    * 15:14:28: The glossary is gonna be big.
    * 15:15:14: reload
* **hoelzro**
    * 15:16:46: alester: are we considering ACK\_OPTIONS to be part of the ackrc logic?
* **alester**
    * 15:17:11: yes
* **hoelzro**
    * 15:17:16: mkay
    * 15:17:26: could you throw that in the notes?
* **alester**
    * 15:17:43: reload
    * 15:18:10: OH! We need a debug mode.
    * 15:18:42: ack --debug
    * 15:18:52: or ack --rule-dump
    * 15:19:47: reload
    * 15:19:58: just added a forkful "Look at glark and see if there's anything we want to steal"
* **hoelzro**
    * 15:20:17: debug++
* **alester**
    * 15:20:59: ack -f started as debug
    * 15:21:04: and now it's a feature
    * 15:23:24: Gimpson: If you and hoelzro want to put your heads together on rules for ackrc finding, that'd be swell.
* **hoelzro**
    * 15:23:34: I'll start a thread
* **alester**
    * 15:25:02: I'm wondering if we should have a separate ack2 list.
    * 15:25:21: Nah, just start it on ack-users
    * 15:25:28: if it gets too noisy, we can split it off.
* **cjm**
    * 15:25:34: agree
* **alester**
    * 15:25:52: hoelzro: A request: Don't start the thread by saying "What do you think it should be?"
    * 15:26:07: Start with "Here's my draft of rules for finding ackrc files in ack 2.0"
    * 15:26:16: because 90% of whatever you come up with in that first draft will be fine.
* **hoelzro**
    * 15:27:18: mkay
* **alester**
    * 15:27:30: And usually when things get opened up to the floor like that, what you come up with is about what you would have had on your own. `:-)`
    * 15:27:35: Attention is a scarce resource.
* **hoelzro**
    * 15:28:03: heh
* **alester**
    * 15:28:23: Anything else in forkfuls anyone's interested in?
    * 15:28:34: or where you see it can be broken up?
* **Gimpson**
    * 15:29:20: Filetype detection, do we know all the new ways we'll support?
* **alester**
    * 15:29:26: yes
* **Gimpson**
    * 15:29:33: extension and regex are the two I know of
    * 15:29:43: shebang
* **alester**
    * 15:29:44: [https://github.com/petdance/ack2/blob/master/ackrc](https://github.com/petdance/ack2/blob/master/ackrc)
* **Gimpson**
    * 15:30:12: Ah, cool.
* **alester**
    * 15:31:54: and then adding some other heuristic like "entirefilematch" for <?php fits nicely
    * 15:32:15: That ackrc is pretty much translated directly from ack 1.x
* **alester**
    * 15:34:36: Hi ad.
    * 15:34:40: Welcome to the party.
* **zitterbewgung-starb**
    * 15:35:34: Hi again.
* **alester**
    * 15:35:36: zitterbewegung: MUST HAVE COFFE
    * 15:35:46: ad: Tell us a bit about your backgroudn.
* **zitterbewgung-starb**
    * 15:35:49: will order you some
* **alester**
    * 15:35:58: zitterbewegung: I prefer my coffee cold.
* **ad**
    * 15:36:01: alester: Just lurking around, thanks
* **alester**
    * 15:36:05: I mean caffeine
* **zitterbewgung-starb**
    * 15:36:14: orders you a cold grande latte
    * 15:36:17: oh wait
* **alester**
    * 15:36:24: lives on diet Coke
* **zitterbewgung-starb**
    * 15:36:27: orders you a cold caffeine IV
    * 15:36:42: oh yea diet coke is great.
* **alester**
    * 15:36:57: OK, so far we have hoelzro going to write up some rules for ackrc/ACK\_OPTIONS
    * 15:37:07: Which I assume will be roughly
    * 15:37:21: in order of priority
    * 15:37:47: ACK\_OPTIONS -> /etc/ackrc -> ~/.ackrc -> project ackrc -> command line switches
    * 15:38:02: from least to most priority
    * 15:38:09: (Gimpson: I guess we ARE talking about rules now :-))
* **hoelzro**
    * 15:38:26: ah, I didn't include command line in my doc
* **alester**
    * 15:38:47: we MUST have the directoriy hierarchy
* **hoelzro**
    * 15:38:58: mkay
* **alester**
    * 15:39:09: because per-project is going to be huge
    * 15:39:28: Because search-all-text-by-default is going to screw up a lot of stuff
* **hoelzro**
    * 15:39:37: hmm
    * 15:39:38: idea
* **alester**
    * 15:39:41: for isntance, here at work, we have plenty of .xml in the source trees
* **hoelzro**
    * 15:39:53: actually, scratch that
* **alester**
    * 15:40:25: and I have to be able to have a .ackrc in my project that says --ignore-file=filetype,xml
    * 15:41:02: oops, I mean --ignore-file=ext,xml
    * 15:41:32: ad: Are you using ack now?
* **ad**
    * 15:41:56: alester: No, but I know what it is
* **Gimpson**
    * 15:43:23: project ackrc is just a .ackrc in a particular directory?
* **alester**
    * 15:43:59: yes
* **hoelzro**
    * 15:44:17: alester: what about --include-file/--include-dir directives?
* **alester**
    * 15:44:26: hoelzro: What about them?
    * 15:44:50: I see ackrc finding & reading to be aggregation of directives.
    * 15:44:56: Nothing more.
* **hoelzro**
    * 15:48:09: just an idea
* **alester**
    * 15:48:37: I don't get what the idea is.
    * 15:49:31: Oh, they don't exist.  You're suggesting explicitly adding --include-file/--include-dir to negate --exclude-file/--exclude-dir?
* **hoelzro**
    * 15:50:02: well, I meant it in the context if including an ackrc file or a directory of them
* **alester**
    * 15:50:44: like --ackrc=/path/to/file ?
    * 15:51:16: Oh, also you have to deal with the $ACKRC variable, too
    * 15:51:34: Or maybe we kill it.
* **cjm**
    * 15:52:23: if we have ./.ackrc, ../.ackrc, etc., we probably don't need $ACKRC
* **alester**
    * 15:52:44: That's what I'm thinking.
* **Gimpson**
    * 15:53:29: Rules are defined completely at runtime before recursing into subdirs?
    * 15:54:03: For example, if I have a .ackrc in ., but there's another in bin/.ackrc, does the .ackrc in bin get used?
    * 15:54:09: When recursing into that directory?
* **cjm**
    * 15:54:32: I don't think so.  Juggling multiple sets of rules will get too complicated
* **alester**
    * 15:54:45: No
    * 15:54:50: we go up looking for .ackrc
    * 15:54:59: not down
    * 15:56:32: One that definitely need to be in the docs is examples.
* **alester**
    * 15:56:42: hi und3f
    * 15:56:46: It's a damn party!
* **und3f**
    * 15:56:57: alester, hello
* **zitterbewgung-starb**
    * 16:00:16: Parttayyy
* **alester**
    * 16:02:57: is running around naked in a circle
    * 16:04:37: OK, are we about done for today?
    * 16:04:47: I'm going to archive this chat for posterity.
* **cjm**
    * 16:04:59: bye, ackolytes
* **hoelzro**
    * 16:05:08: sounds good
* **ad**
    * 16:05:09: Just a quick question
* **alester**
    * 16:05:19: Thanks to all of you for showing up.  We definitely need to do this again.  People are clearly interested.
    * 16:05:20: Yes, ad?
* **ad**
    * 16:05:34: Any non core modules required now or in the future?
* **alester**
    * 16:05:41: [File::Next](File::Next) is it.
    * 16:06:03: What makes you ask?
* **ad**
    * 16:06:10: Ok, need to look for an easy way to deploy on FreeBSD
* **alester**
    * 16:06:37: How do you mean?
* **ad**
    * 16:07:10: I mean, I don't want to install ad hoc in every machine
* **alester**
    * 16:07:18: Sure.
    * 16:07:36: I don't see anything on betterthangrep.com where someone has packaged ack
    * 16:07:47: Does FreeBSD have some package system?
* **ad**
    * 16:07:57: Yes, FreeBSD ports
* **alester**
    * 16:07:57: It's in Macports
    * 16:08:04: OK, so someone needs to package ack.
* **ad**
    * 16:08:09: And there is something called bedpan
    * 16:08:17: Damn autocorrect!
    * 16:08:21: Bsdpan
* **alester**
    * 16:08:53: I don't know anything about BSD's packaaging (or anyone's really)
    * 16:09:01: So we'll have to rely on someone else.
    * 16:09:10: Or you can install with "sudo cpan App::Ack"
* **ad**
    * 16:09:25: I was trying to avoid that
* **alester**
    * 16:09:34: Which "that"?
    * 16:09:37: cpan shell?
* **ad**
    * 16:09:41: Yes
* **alester**
    * 16:09:47: Understood.
* **ad**
    * 16:10:24: I'll play around and let you know if there is a way
* **alester**
    * 16:10:35: It would be useful for ack 1.x, too.
* **ad**
    * 16:11:03: You're Andy Lester of perlbuzz, right?
    * 16:11:18: I 'll know how to contact you, then
    * 16:11:38: Yes, for 1.x too
* **alester**
    * 16:12:27: That's me.
    * 16:12:35: There's an ack-users mailing list, too.
* **ad**
    * 16:12:43: Noted
* **zitterbewgung-starb**
    * 16:13:18: Do you need someone to package ack for macports?
* **alester**
    * 16:13:27: It's already there, zitterbewgung-starb
* **zitterbewgung-starb**
    * 16:13:31: oh ok
* **alester**
    * 16:13:35: see betterthangrep.co
    * 16:13:37: .com
* **zitterbewgung-starb**
    * 16:13:48: ok nvm
    * 16:13:58: this chat was fun `:-)`
* **alester**
    * 16:15:32: It was, wasn't it?
    * 16:15:36: And isn't that why we do this?
    * 16:15:45: I will definitely schedule more.
* **hoelzro**
    * 16:16:18: sounds good to me!
* **alester**
    * 16:16:49: Yes, and thanks espeically to hoelzro for kicking me in the ass to get ack 2.0 going again. `:-)`
* **zitterbewgung-starb**
    * 16:16:55: `:-)`
    * 16:17:09: Looks like we even have parts of 2.1 planed out too
* **alester**
    * 16:17:14: but to all of you for showing up and helping and commenting and (presumably) spreading the word about ack.
* **zitterbewgung-starb**
    * 16:17:38: heard about this from your twitter.
* **alester**
    * 16:17:50: zitterbewgung-starb: Which one?  @petdance or @perlbuzz?
* **zitterbewgung-starb**
    * 16:18:32: petdance
* **alester**
    * 16:18:49: I have a todo for Mondy morning to point @petdance people to @perlbuzz and vice versa.
* **zitterbewgung-starb**
    * 16:19:10: oh ok i can follow the other one then
* **alester**
    * 16:19:52: zitterbewgung: Holy cats, you're local, too.
    * 16:20:03: Would you be up for in-person ackathonning, too?
* **zitterbewgung-starb**
    * 16:20:11: Uh possibly
* **alester**
    * 16:20:14: I'm in McHenry, hoelzro is in Madison
* **zitterbewgung-starb**
    * 16:20:18: I don't know much perl
    * 16:20:22: but i'm a quick learner
* **alester**
    * 16:20:22: ok
* **zitterbewgung-starb**
    * 16:20:36: I taught myself python pretty fast
* **alester**
    * 16:20:42: As we've seen this morning,the power of having people together is pretty strong.
* **ad**
    * 16:21:08: Afternoon here `:)`
* **zitterbewgung-starb**
    * 16:23:25: alester: I met you at barcamp . I am located in Darien.
    * 16:23:39: alester: I gave a presentation at barcamp on quantum computation and I bought your book
* **alester**
    * 16:23:58: oh, cool
    * 16:24:05: Did the book do you any good?
* **zitterbewgung-starb**
    * 16:24:28: alester: Well I am probably going to use it in about 6months
* **alester**
    * 16:24:36: Use it NOW
* **zitterbewgung-starb**
    * 16:24:36: Once i finish my degree.
    * 16:24:43: Yea I should
* **alester**
    * 16:24:46: start your resume now
* **zitterbewgung-starb**
    * 16:25:01: Yea you sent me back my resume and I am going to revise it now
* **hoelzro**
    * 16:28:33: well, I'm outta here people
    * 16:28:41: gotta help my girlfriend with the food-makings.
    * 16:29:03: later!
* **zitterbewgung-starb**
    * 16:29:05: hoelzro: Have fun `:-)`

branch_name: refs/heads/dev

gha_language: Perl

gha_license_id: NOASSERTION


text:
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html) since its version 0.1.1.

## [Unreleased]

## [0.2.4] - 2019-10-18
### Changed:
 - Fix: add missing migration file

## [0.2.3] - 2019-09-26
### Changed:
 - Fix: fix the path validation allowing changes by path resolved/handled by deeppages.views.

## [0.2.2] - 2019-09-26
### Changed:
 - Fix: add compatibility with Wagtail CMS

## [0.1.9] - 2018-12-06
### Changed:
 - Fix: add 'app_name' in urls.py

## [0.1.8] - 2018-07-19
### Changed:
 - Fix: add new migration in favor of model's field Page.created_at

## [0.1.7] - 2018-05-17
### Changed:
 - Fix: stupid error - forgot to import ObjectDoesNotExist (I'm shame about it)

## [0.1.6] - 2018-05-15
### Changed:
 - Fix: was a wrong code to detect and validate the page requested extension

## [0.1.5] - 2018-03-26
### Changed
 - Fix: there was a bug when we're using Middleware way and PageView was not configured.

## [0.1.4] - 2018-03-26
### Changed
 - Fix a stupid bug has been fixed after functions names refactoring
 - Fix images referenced in README.md

## [0.1.3] - 2018-03-26
### Added
 - Fix normalize_path() function to check if deeppages' path isn't the root path, otherwise change the requested path to compare with existent deep pages

## [0.1.2] - 2018-03-22
### Added
 - Refactor function get_page_by_path() in utils.py.
 - Add new function get_page_by_name() in utils.py.
 - Rename function render_template to render_content() in utils.py.
 - Add new function render_page() in utils.py.
 - Add new function render_requested_page_content() in utils.py.
 - Add new method render() on Page model returning a rendered template.
 - Add this CHANGELOG file based on keepachangelog.com.
 - Add new function is_acceptable_file_type() used for valid file type verification and avoid non-text-based content.

## [0.1.1] - 2018-03-21
### Changed
 - Add missing migration directory with initial migration (0001-initial.py) into dist package.

## [0.1] - 2018-03-21
### Added
 - First beta version published.

repository: ricardofalasca/deep-pages

repo_name: ricardofalasca/deep-pages


text:
## Configuring project on HPC server
*Note:* Assuming we are testing project named `hello-world`.

1. Login to HPC server and clone `ci-hpc` repository:
```shell
cd $WORKSPACE # directory where you keep your projects
git clone https://github.com/janhybs/ci-hpc.git
cd `ci-hpc`
```

2. Install necessary pip packages:

   Execute `install.sh` script located in the `bin` folder.
   By default it will install the packages for the current user (no root required).
   **It is expected to have `python3` and `pip3` in the path.**
   ```bash
   bin/install.sh
   ```
   To install packages system wide, add flag `--system`:
   ```bash
   bin/install.sh --system
   ```

3. Create configuration file `config.yaml` for the project
```shell
export PROJECT_NAME=hello-world

mkdir -p cfg/$PROJECT_NAME
nano     cfg/$PROJECT_NAME/config.yaml
```

4. Setup `config.yaml` configuration file

*Please refer to [config.yaml](config.yaml.md) section to find out more
about configuration.*

[« back to docs](README.md)

repository: elichad/ci-hpc

repo_name: elichad/ci-hpc


text:
Working with Sprites
===================
The Predigame sprite is a generic two-dimensional object that is integrated with other sprites in a larger scene. A sprite can consist of a bitmap (still) image or a basic geometrical shape (circle, rectangle, ellipse). Sprites in Predigame have some fun properties - they can be clicked, collide with other sprites, even fade, spin or pulse.

Let's have fun working with Sprites!

Getting Started
----------
To get things started, we're going to create a basic Predigame canvas that we'll use to place sprites. The canvas will have a width of 30 grid cells and a height of 20 grid cells.

```python
WIDTH = 30
HEIGHT = 20
TITLE = 'Sprites Demo'
```
Save your changes. Let's call the file `sprite-demo.py`.  Try running the game from the terminal using the `pred` command (you'll want to run this command from the directory where you saved the file).

    my_machine$ pred sprite-demo.py

This program doesn't do much just yet. Just an empty window titled "Sprites Demo". So boring. We're going to add some more code, but first let's make sure we understand grid coordinates and how to place sprites within those coordinates.

Understanding Grid Coordinates
-------------
Probably the easiest way to understand grid coordinates is to enable the `grid()` overlay in the game code.

```python
WIDTH = 30
HEIGHT = 20
TITLE = 'Sprites Demo'

# enable the grid overlay
grid()
```
Save your code and try running the this version using the same command:

    my_machine$ pred sprite-demo.py

The result should look like the figure below. Counting the grid coordinates will show **30** from *left to right* and **20** from *top to bottom*. This doesn't address how to address sprites using grid coordinates, we'll cover that next.

![alt text](http://predicate.us/predigame/images/sprites_grid.png "Predigame Grid Coordinates")

The following code will show how to place rectangle sprites in each of the four corners of the window.

```python
# top/left
shape(RECT, RED, (0, 0))

# bottom/left
shape(RECT, BLUE, (0, HEIGHT-1))

# top/right
shape(RECT, PINK, (WIDTH-1, 0))

# bottom/right
shape(RECT, PURPLE, (WIDTH-1, HEIGHT-1))
```
Saving and running the code will show:
- a RED rectangle at position `(0, 0)` corresponding to the top-left corner
- a BLUE rectangle at position `(0, HEIGHT-1)` corresponding to the bottom-left corner
- a PINK rectangle at position `(WIDTH-1,  0)` corresponding to the top-right corner
- a PURPLE rectangle at position `(WIDTH-1, HEIGHT-1)` corresponding to the bottom-right corner

#### *Why are the corners specified as `WIDTH-1` and `HEIGHT-1`*?
Computers always start counting at zero. So if `WIDTH = 30` and the first grid is `0` the thirtieth cell would be `WIDTH-1` or `29`.

Running this code should look like the figure below.
![alt text](http://predicate.us/predigame/images/sprites_grid2.png "Predigame Grid Coordinates")

We added a few labels to make the grid coordinates a little more easier to visualize. It's possible to replace the code from the previous exercise with the one here:

```python
# place on center of screen
text("Understanding Grid Coordinates", color=BLACK, size = 2.0)
text("this is a 30 x 20 window", color=BLACK, pos=(WIDTH/2-7, HEIGHT/2+1), size = 1.75)

# top/left
shape(RECT, RED, (0, 0))
text("(0, 0)", RED, pos = (0,1), size = 1.25)

# bottom/left
shape(RECT, BLUE, (0, HEIGHT-1))
text("(0, " + str(HEIGHT-1) + ")", BLUE, pos = (0, HEIGHT-2), size=1.25)

# top/right
shape(RECT, PINK, (WIDTH-1, 0))
text("(" + str(WIDTH-1) + ", 0)", PINK, pos = (WIDTH-2.5,1), size = 1.25)

# bottom/right
shape(RECT, PURPLE, (WIDTH-1, HEIGHT-1))
text("(" + str(WIDTH-1) + ", " + str(HEIGHT-1) + ")", PURPLE, pos = (WIDTH-3,HEIGHT-2), size = 1.25)
```

The resulting game window will show the following rendering:
![alt text](http://predicate.us/predigame/images/sprites_grid3.png "Predigame Grid Coordinates")

Creating Shapes
-------------
There are two types of sprites supported in the Predigame platform - shapes and images. Let's look at shapes. The formal *function definition* (or signature) for creating a shape is as follows:

```python
shape(shape = None, color = None, pos = None, size = (1, 1))
```
Reading this code, there are four **attributes**:

1. `shape` - the type of shape to create. Can be one of RECT, SQUARE, CIRCLE, or ELLIPSE
2. `color` - the shape's color. Can be a constant like BLACK, BLUE, or RED, as well as a (red, green, blue) tuple such as (128, 128, 128)
3. `pos`   - the grid cell of the shape
4. `size`  - the size of the shape in terms of grid cells using the form (width, height). For CIRCLE shapes, only the first number is considered.

Notice that each of these attributes have default values. This means that they are option, and if not specified, Predigame will create a random shape type of random color, size, and position.

```python
# draw a random shape type of random color, size, and position
shape()
```

Here are a few example shapes we can add to our canvas:
```python
# red circle at position (2, 2)
shape(CIRCLE, RED, (2, 2))

# create a big blue circle next to the red one
shape(CIRCLE, BLUE, (5, 1), 3)

# create a 2x2 ORANGE square at position (10, 2)
shape(RECT, ORANGE, (10, 2), (2,2))

# create a 6x1 rectangle
shape(RECT, AQUA, (15, 2), (6, 1))

# create a custom colored (r, g, b) ELLIPSE
shape(ELLIPSE, (134, 134, 134), (23, 2), (5, 2))
```
If we add each of the above shapes to our code, the resulting file will look like this:
```python
WIDTH = 30
HEIGHT = 20
TITLE = 'Sprites Demo'

# red circle at position (2, 2)
shape(CIRCLE, RED, (2, 2))

# create a big blue circle next to the red one
shape(CIRCLE, BLUE, (5, 1), 3)

# create a 2x2 ORANGE square at position (10, 2)
shape(RECT, ORANGE, (10, 2), (2,2))

# create a 6x1 rectangle
shape(RECT, AQUA, (15, 2), (6, 1))

# create a custom colored (r, g, b) ELLIPSE
shape(ELLIPSE, (134, 134, 134), (23, 2), (5, 2))
```
Save and run this code. The result should look similar to the image below:
![alt text](http://predicate.us/predigame/images/sprites_grid4.png "Predigame Grid Coordinates")

Creating Images
-------------
Like shapes, the Predigame platform also supports creating images. The formal *function definition* (or signature) for creating an image is as follows:

```python
image(name = None, pos = None, center = None, size = 1)
```
Notice that it is similar, yet slightly different than the code for creating a shape. An image in Predigame is defined by:

1. `name` - the name (without extension) of the image file. The image file should be stored in the **images/** directory. For example, if we had an image "coke.png" in our **images/** directory, the name of the image would be "coke".
2. `pos` -  the grid cell of the shape. Officially, this will be the top-left cell of the image.
3. `center` - used as an alternative to `pos` to use this position as the center point.
4. `size` - the size of the shape in terms of grid cells. By default, the image will be fit into a single grid cell.

Notice again that each of these attributes have default values. This means that they are option, and if not specified, PrediGame will select a random image from the **images/** directory of size `1` (so it will fit into a single cell) and will be placed at a random position.

Now here are a few example shapes we can also add to our canvas:

```python
# create a "sprite" sprite and place at grid location (2, 8)
image('sprite', (2, 8))

# create a "coke" sprite of double size and place at grid (7, 8)
image('coke', (7, 8), size = 2)

# create a zombie
image('zombie-1', (13,9), size = 5)

# create another zombie
image('zombie-2', (19,9), size = 5)
```
Add the above lines to our code file and save the changes. The result should look similar to the image below:
![alt text](http://predicate.us/predigame/images/sprites_grid5.png "Predigame Grid Coordinates")

Sprite Effects
-------------
Drawing sprites can be a lot of fun, however, we can add some effects to bring them to life. For example, we can make sprites spin, float, and even pulse. Let's look at the some new sprites with effects attached.

### Spinning
```python
image('sprite', (2,14)).spin(time=1)
```
This sprite will spin and complete a revolution every second. It's possible to change `time` to a smaller or larger number to increase or decrease the spin rate.

### Pulsing
```python
image('sprite', (7,14)).pulse(time=0.5, size=3)
```
Have the sprite execute a pulsing effect - rapidly expand and shrink. The `size` attribute will control the maximum size of the sprite (as a multiplier) during expansion. The `time` attribute sets the amount of time (in seconds) the sprite will take to complete an expansion or contraction.

### Floating

```python
image('coke', (13, 15), size = 2).speed(1).float(distance=1)
```
Have the sprite float in place. The `.speed(1)` call sets the speed of the movement and the `distance` attribute sets the amount of room (in term of grid cells) the sprite will use to complete a floating operation.

Sprite Event Callbacks
-------------
When we code a game we sometimes need to create actions that will eventually occur. Think of a mouse trap. It doesn't do much until, you know, the mouse comes by and eats the cheese. In code we define callback functions -- they don't do anything until a certain event, like a mouse click, occurs in the game.

The Python program language requires that we specify our functions before registering them in the code. Let's look at a simple callback example.

```python
def destroy(s):
    s.destroy()
```
This function will simply destroy a circle anytime one is clicked. Functions don't work until they are called, or in the case of callbacks, until they are registered.

```python
s = shape(CIRCLE, RED, rand_pos()).clicked(destroy)
```
That's right.. We can basically add a `.clicked(destroy)` to the end of our shape definition and register a callback function that won't get called until the player clicks on the circle.

Let's take a look at few more examples of event callbacks.

### Click Events
We already briefly covered a click example, but let's look at one that is a little more complicated.

```python
def doit(s):
    s.destroy()
    image('kaboom', center=(15, 10), size=25)

image('clickme', (19, 15), size = 2).pulse(time=0.05, size= 1.25).clicked(doit)
```
This example creates a fast pulsing `clickme` sprite that is destroyed when clicked and replaced with an oversized  `kaboom` image.

```python
s = image('coke', (13, 15), size = 2)
s.speed(1).bouncy().spin().pulse().clicked(s.destroy)
```
This example is similar to our first mouse click example on the shape but it recycles the sprites `destroy()` method as a callback - `.clicked(s.destroy)`. It also chains a whole bunch of effects that make this sprite bounce around the canvas, pulse, and even spin.

### Keyboard Events
We can also control a sprite with the keyboard.

```python
image('zombie-1', (28, 18), size = 2).keys()
image('zombie-2', (25, 18), size = 2).keys(right='d', left='a', up='w', down='s')
```
In this case `zombie-1` is registered with the `.keys()`function which will control the sprite with keyboard arrow buttons. In the case where we'd like to use other keyboard buttons, such as a multi-player game, we can assign new keys - `.keys(right='d', left='a', up='w', down='s')`.

### Collisions
It's common in some games, like FPS, to want to check for sprites that collide with each other.  Let's take our previous keyboard example and check for collisions.

```python
def eatit(z, s):
    s.destroy()
    z.scale(1.2)

image('zombie-1', (28, 18), size = 2).keys().collides(sprites(), eatit)
image('zombie-2', (25, 18), size = 2).keys(right='d', left='a', up='w', down='s').collides(sprites(), eatit)
```
Here we **chain** the `.collides()` callback which takes in a list of sprites and registers a callback function. As coded, we register both zombies to check for collisions with all sprites, the `sprites()` call will return all sprites on the canvas, and invite the `eatit` callback function.

repository: predicatemike/predigame-examples

repo_name: predicatemike/predigame-examples


text:
# gitlab-hook-server

This small node.js server allow to execute commands on a machine (deployment scripts for example) when a GitLab webhook is triggered (push, issue events, etc..).

The server use a basic configuration file which defines which command should be executed on specific event of a specific repository. The setup time is around 15 minutes.

## Requirements

Node.js (v6 or greater)

## Installation

- Download the content of the current repository
- Execute the following command in the downloaded folder : `npm install`
- Create the file "config.json" and fill it with your configuration (see the server configuration part below)
- If needed, open the port set in the configuration in your firewall in order to allow http request on the server
- Execute the following command in the downloaded folder : `node server.js` (you can also use a process manager like pm2)
- Add the URL of the current server in your gitlab configuration (see the gitlab configuration part below)

## Server configuration

Example of a configuration file :

```
{
  "port": 9000,
  "logfile": "/home/user/gitlab-hook-server.log",
  "hooks": [
    {
      "repository": "my-gitlab-repository",
      "event": "push",
      "token": "my-gitlab-token",
      "command": "sh /home/user/deploy.sh 'firstParam' '${after}' '${repository.name}' --user='${user_name}'"
    }
  ]
}
```

- **port**: The port on which the server is gonna be started
- **logfile**: The file in which the logs will be written. Can be a relative path (from the server folder) or an absolute path. (optional. if null, the logs will be displayed in the console)
- **hooks**: List of hooks that you want to bind
  - **repository**: Name of the repository on which the command must be bound (optional. if null, the command will be executed on events of all repositories.
  - **event**: Name of the event on which the command will be executed (see the possible values on the [gitlab documentation](https://gitlab.com/help/user/project/integrations/webhooks)) (optional. if null, the command will be executed on all events)
  - **token**: The gitlab token define in the gitlab configuration (see gitlab configuration part below) (optional)
  - **command**: The command to execute when the hook is triggered. `${tokens}` will be replaced by values from the request body sent by [Gitlab](https://gitlab.com/help/user/project/integrations/webhooks#push-events).

## GitLab Configuration

- Open the repository that you want to bind in the gitlab website
- Go to "Settings", and then "Integrations"
- In the URL field, type the address of the hook server : `http://<server-name>:<port>/event`
- Set a token if needed
- Select the event that you want to trigger
- Click on "Add webhook"
- Once the operation done, click on the "Test" button to check if the binding is working

repository: Paul-DS/gitlab-hook-server

repo_name: Paul-DS/gitlab-hook-server