text:
---
layout: default
---

# 1993-08-15 - Cypherpunk trends & visions

## Header Data

From<EMAIL_ADDRESS>(Nick Szabo)

To<EMAIL_ADDRESS>Message Hash: 9310515e3b5c3b3c7f4568e1851662a5d6f2010c38c217f52425023919e8bab6

Message ID<EMAIL_ADDRESS>Reply To: _N/A_

UTC Datetime: 1993-08-15 08:56:49 UTC

Raw Date: Sun, 15 Aug 93 01:56:49 PDT

## Raw message

```
{% raw  %}From<EMAIL_ADDRESS>(Nick Szabo)
Date: Sun, 15 Aug 93 01:56:49 PDT
To<EMAIL_ADDRESS>Subject: Cypherpunk trends & visions
Message-ID<EMAIL_ADDRESS>MIME-Version: 1.0
Content-Type: text/plain

At today's Silly Valley cypherpunks meeting (Tim May, John
Gilmore, Eric Hughes, Sandy Sandfort, Whit Diffie,
Romana "Cypherella" Machado, etc. etc.) there was a lot of
hand-wringing about the cypherpunks movement "stalling".  Ever the
pessimist, Tim May drew a chart showing cypherpunks starting out
with a bang (publicizing PGP, starting up anon remailers, etc.)
and seeming to stall out (even as we've gotten major publicity
in Mondo, Wired, Village Voice, etc.).

Much of the rancor and pessimism may reflect the fact that
cypherpunks are more distributed now.  For example, the stuff
on this list is very disconnected from the Bay Area meetings.  Do any
non-Californians know or care about Digital Silk Road, electronic
credit unions, Twain, etc?  How hip are Bay Area cypherpunks to the
various projects re: user-friendly PGP, CryptoStacker,
securely private BBS's, secure phones, etc?  (The main motivation
for me typing in this message is to try to open up the lines
of communication more, let people know what Bay Area cypherpunks
are doing, and encourage replies from folks in other regions
who are holding meetings & doing projects).

Besides, we haven't stalled; we're just on a more mature part
of the learning curve.  Much of the "low hanging fruit" has
been picked (as Tim May pointed out: PGP was already here,
remailers were ripe, etc. when cypherpunks crystallized).
We seem to have played a major role in delaying Clipper just with
our big mouths (and fat fingers :-).  More concretely, just today Romana
and Geoff Dale unveiled a slick steganography tool for the Mac that,
if distributed widely and ported to the PC, would make it practically
impossible to outlaw strong crypto.

We also have a variety of goals.  We all share
a commitment to spreading crypto beyond the elites, but for
a wide variety of reasons.   Some of us (Tim May, myself, etc.)
are libertarians who want government out of our
lives, others are liberals fighting the NSA, others
find it great fun to ding people in power with cool hacks,
and still others are in it for the variety of opportunities
crypto-anarchy opens up for making "filthy lucre".

I don't think it's productive to do too much breastbeating over this,
to try to define "cypherpunk correct" politics, or insist that everybody
work towards the same goals.  The only stuff we really need to agree on is
the practical stuff: the general "web of trust" model of
cryptography, and the development of common tools and standards on that
basis.  Beyond that I hope there's room for a wide variety of
opinions and projects.

My own vision of cypherpunks evolution runs along the following
lines.  Some of these may be commercial opportunities, but
so far cypherpunks have been most effective with freeware like
anon remailers, PGP add-ons, etc.:

* Digital coupons: S&H greenstamps for online services
(netcom/Well/Compuserve net connection services, AMIX,
NEXIS/LEXIS, Dow Jones, commercial MUDs, metered e-mail, anon
services, network and computing resources, reputation ratings,
etc.)  Greenstamps are like frequent-flyer miles, you accumulate
them with heavy patronage of some service.  But greenstamps
can be used to purchase a wide variety of services, not just
more of the same service.  Service providers and
coupon vendor(s) work out arrangements for awarding and honoring
greenstamps.  Implemented with Chaum-style protocol to prevent
forgery and assure privacy.
* Digital cash: accumulating credits/debits for use of on-line
services (including travel services, concert tickets, etc.
purchased on-line), eventually paid for by some "real" currency:
FRNs, yen, etc.  Implemented with Chaum-style protocol to prevent
forgery and assure privacy.
* On-line markets: Internet video poker, election outcome
markets, satellite track betting, etc.  Investments[1] can be
made & paid out by greenstamps, natch.  On-line advertising.
* Securely private BBS's
* etc.

[1] Hey, if Clinton can call government spending "investment"
I can do the same for wagers on his reelection!

Nick Szabo<EMAIL_ADDRESS>

{% endraw %}
```

## Thread

+ Return to [August 1993](/archive/1993/08)

+ Return to<EMAIL_ADDRESS>(Nick Szabo)](/authors/szabo_at_netcom_com_nick_szabo_)"

+ 1993-08-15 (Sun, 15 Aug 93 01:56:49 PDT) - Cypherpunk trends & visions -<EMAIL_ADDRESS>(Nick Szabo)_


text:
---
day: '115'
title: React Chat App
date: 2018-02-06T04:00:34.039Z
tags:
  - 100daysofcode
  - javascript
  - react
categories: code
weight: 0
---
# Day 115

## Today's Progress

Created the basic UI of the app.

## Thoughts

I had trouble linking to the [**Press Start 2P Font**](https://fonts.google.com/specimen/Press+Start+2P). I found [this on SO](https://stackoverflow.com/a/47733243/270847), which told me to add an **`@import`** statement to the top of my **`App.css`** file.

```
@import url("https://fonts.googleapis.com/css?family=Press+Start+2P");
```

## Links

* [Initial commit](https://github.com/thomasphillips3/react-chat-app/commit/706f6f21eb53be22ef697555eff485db95418cfc)

license: MIT

branch_name: refs/heads/master

extension: md

gha_language: CSS

gha_license_id: MIT

license_type: permissive


text:
# Code Challenge - GP

Code challenge.

## Dependencies

This project uses some ES6 features and we use [BabelJs](https://babeljs.io/) in order to get things working well.

## Tests

This project uses [Mocha](https://mochajs.org/) and [ExpectJS](https://github.com/Automattic/expect.js) to execute tests.

```
npm run test:tdd
```

## Methods

> Follow the methods that the project provides.

### getLastUpdatedList(..args:*array*)

> Return an array without any duplicate item and sorted by "lastModified"

**Example**

```js
let firstObj = { id: 1, lastModified: new Date('2005-12-17T03:24:00') };
let secondObj = { id: 2, lastModified: new Date('1995-12-17T03:24:00') };
let thirdObj = { id: 3, lastModified: new Date('1999-12-17T03:24:00') };
let fourthObj = { id: 4, lastModified: new Date('2017-11-25T03:24:00') };

let list = [firstObj, secondObj, thirdObj, fourthObj];

let secondList = [
      { id: 5, lastModified: new Date('1857-12-17T03:24:00') },
      thirdObj, firstObj];

const resultList = getLastUpdatedList(list, secondList);

/*resultList => [
      { id: 5, lastModified: new Date('1857-12-17T03:24:00') },
      secondObj, thirdObj, firstObj, fourthObj]*/
```

### concatList(..args:*array*)

> Return an unique Array.

**Example**

```js
const firstList = [1, 2, 3];
const secondList = [1, 2, 'three'];
const uniqueList = concatList(firstList, secondList);

//uniqueList => [1, 2, 3, 1, 2, 'three']
```

### removeDupl(array)

> Remove all duplicate item of an Array.

**Example**

```js
const list = [1, 2, 3, 1, 2, 'three'];
const resultList = removeDupl(list);

//resultList => [1, 2, 3, 'three']
```

### sortList(array)

> Sort an array of object from the oldest to the newest using 'lastModified' property.

**Example**

```js
let firstObj = { id: 1, lastModified: new Date('2005-12-17T03:24:00') };
let secondObj = { id: 2, lastModified: new Date('1995-12-17T03:24:00') };
let thirdObj = { id: 3, lastModified: new Date('1999-12-17T03:24:00') };
let fourthObj = { id: 4, lastModified: new Date('2017-11-25T03:24:00') };
let list = [firstObj, secondObj, thirdObj, fourthObj];

const resultList = sortList(list);

//resultList => [secondObj, thirdObj, firstObj, fourthObj]
```

## Contributing

Please read [CONTRIBUTING.md](https://gist.github.com/PurpleBooth/b24679402957c63ec426) for details on our code of conduct, and the process for submitting pull requests to us.

## Versioning

We use [SemVer](http://semver.org/) for versioning. For the versions available, see the [tags on this repository](https://github.com/your/project/tags).

## Authors

[Vinicius Araujo](https://github.com/vinicius-araujo/)

See also the list of [contributors](https://github.com/vinicius-araujo/dazn-challenge/contributors) who participated in this project.

## License

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

repository: vinicius-araujo/gp-challenge

repo_name: vinicius-araujo/gp-challenge


text:
# [Orbs Voting UI](https://orbs-network.github.io/voting/)
> Voting UI is a webapp hosted at [github pages](https://orbs-network.github.io/voting/) where stakeholders can delegate their votes to guardians. Guardians in turn can vote for different validators and get rewards.

## Local dev
Local setup consist of two three parts: 1) web client, 2) metamask extension and 3) ganache. This guide will explain both parts.
1. Setting up local blockchain
    1. Download and install [Ganache](https://truffleframework.com/ganache).
    1. Launch Ganashe.
    1. Navigate to `voting/ethereum`.
    1. Run `npm install`.
    1. Run `npm run migrate`. This will deploy Ethereum smart contracts to your local blockchain.
    1. Open Ganache. You should see 3 contract deployed in transactions.
    1. Take contract addresses from transactions
    1. Run `npm run contracts:local`
1. Running `client-web`
    1. Clone the project `git clone https://github.com/orbs-network/orbs-ethereum-contracts`. This project is a monorepo. The interesting part for us is `Voting` folder. It contains contract and client side.
    1. Navigate to `client-web` folder `cd voting/client-web`.
    1. Run `npm install`.
    1. Run `npm start`.
    1. Go to [http://localhost:3000](http://localhost:3000) and see the app running.
1. Configuring Metamask extension
    1. Install [Metamask extension](https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn?utm_source=chrome-ntp-icon)
    1. Open Ganache, click on `Accounts` tab and then click on `key` icon of the first account.
    1. Copy its private key.
    1. Create account in Metamask and import the key.

It's a little bit of a hustle, but at the end, you should be able to delegate and vote in the app.

## Tests
1. Unit and Component tests
    1. Run `npm run test`
1. E2E tests
    1. Go to `voting/test/e2e`
    1. Run `npm test`

## Deploy
1. `npm run contracts:prod`
1. `npm run deploy`
1. [https://orbs-network.github.io/voting/](https://orbs-network.github.io/voting/)

gha_license_id: NOASSERTION


text:
# Socket Sample (Windows)

This is a Linux-based socket sample.
Use it to explore client and server communication.

- What is the sequence on the server side and client side?
- What can happen in parallel? Across sides and within each side?

# Next step

Currently, the server accepts the connection
and waits for data from the client.

Change the server and the client,
for the server to respond with a 'certificate' first.
The certificate is in the form of a structure

```C
struct Certificate
{
    char name[38];
    unsigned int hash;
};
```

repository: sreemoyeemukherjee/SocketProgramming

repo_name: sreemoyeemukherjee/SocketProgramming


text:
![license](https://img.shields.io/github/license/dev-caspertheghost/ghostybot?color=gr)
![contr](https://img.shields.io/github/contributors/dev-caspertheghost/ghostybot)
![stars](https://img.shields.io/github/stars/dev-caspertheghost/ghostybot?color=gr)

A Custom Discord bot written in TypeScript with a lot of commands for Discord communities. (+205 commands) Economy, util, fun, music, admin, xp system, welcome messages, audit-logs and more!

[![Add ghostybot](./.github/add-to-discord.png)](https://discord.com/oauth2/authorize?client_id=632843197600759809&scope=bot&permissions=8)
[![Ghostybot Support server](./.github/join-support-server.png)](https://discord.gg/XxHrtkA)

### Disclaimer (if self-hosted)

You are not allowed to upload this bot to any service such as discordbotlist or top.gg, you are only allowed to host this bot for your community. When self-hosting no support will be provided.

## Table of contents

- [Features](#features)
- [Commands](docs/COMMANDS.md)
- [Docs](docs/README.md):
  - [Add translation](docs/TRANSLATE.md)
  - [Installation](docs/INSTALLATION.md)
    - [Requirements](docs/INSTALLATION.md#requirements)
    - [Usage](docs/INSTALLATION.md#usage)
  - [Contributing](docs/CONTRIBUTING.md)
  - [Bot Events](/docs/BOT_EVENTS.md)
  - [API's used](/docs/APIS_USED.md)
- [License](#license)
- [Legal](#legal)

## Features

- Easy to use
- A dashboard where you can easily manage the bot's settings
- Reaction Roles
- Enable/disable welcome messages
- Play games
- Use util commands to get your avatar, botinfo, channelinfo and more
- Play music
- Get animal pictures/gifs
- XP system
- Economy system
- verify system
- And more!

## Commands

Commands have been moved [to their own file](docs/COMMANDS.md)

## Docs

[View docs](/docs/README.md)

## Support ghostybot

### All stars/forks are appreciated! ⚡

**Feel free to open a pull request with a new feature.**

Made with ❤ and TypeScript!

## License

[Apache © Dev-CasperTheGhost](./LICENSE)

## Legal

If you have any concerns about your data, privacy or security, please [join our support guild](https://discord.gg/XxHrtkA) and look for the "❗ Legal" category.

repository: XplayzHD/ghostybot

branch_name: refs/heads/main

repo_name: XplayzHD/ghostybot


text:
### Programming Industrial Strength Windows

[« Previous: Child Windows](Chapter-8-Child-Windows.md) — [Next: Customization and Persistence »](Chapter-10-Customization-and-Persistence.md)

# Chapter 9: The Main Window

The **mainWndProc** function (in mainwnd.cpp) implements the window function for TextEdit’s main window, and is the central switchboard of TextEdit. To do the switching, it employs the message cracker macros in windowsx.h. Even though mainWndProc contains the big switch statement of traditional window functions, the `HANDLE_MSG` macro delegates each message to an appropriate handler function in a – sort of – type-safe manner. At least the programmer doesn’t need to worry about the parameter packing for the various messages. Furthermore, the macros are portable between Win16 and Win32. This is particularly important for messages such as `WM_COMMAND`, where the parameter packing changed.

## Handling `WM_COMMAND` messages

The onCommand handler function is a switchboard within a switchboard. In the same way that mainWndProc farms out message handling to individual functions, onCommand farms out command handling to individual functions. The only exception is the range of commands `ID_MRU_1` through `ID_MRU_9`, which is handled directly in onCommand. The command handlers could have been extended to handle ranges of commands, of course, but it hardly seems worth the bother.

One surprise is the existence of both `ID_EDIT_FINDNEXT`, which is on the menu, and `ID_ACCEL_FINDNEXT`, which is the command sent by the accelerator key F3. Yet both commands map to the onEditFindNext function. How come?

The reason is that the menu command “Find Next” is disabled when no previous search exists. If F3 mapped to `ID_EDIT_FINDNEXT`, this accelerator key would also be disabled. I do want it to do something, though: behave as though `ID_EDIT_FIND` had been selected. This is handled easily enough in onEditFindNext; the whole point of using two command IDs is to avoid disabling the accelerator merely because the menu item is disabled.

Some command handlers are pure debug scaffolding: onDivideByZero, onAccessViolation, onOutOfMemory and onStackOverflow. Their only purpose is to exercise the exception handling; they are excluded from release builds.

TestClass is used to verify proper stack unwinding when an exception is thrown; all it does is trace its construction and its destruction:

```C++
class TestClass {
public:
   TestClass () { trace( _T( "TestClass ctor\n" ) ); }
   ~TestClass() { trace( _T( "TestClass dtor\n" ) ); }
};

PRIVATE void onAccessViolation( HWND ) {

   TestClass testClass;

   lstrcpy( 0, _T( "uh-oh!" ) ); // No exception
   _tcscpy( 0, _T( "uh-oh!" ) ); // Exception
}
```

My first implementation of onAccessViolation used lstrcpy to force an access violation. This failed though, in the sense that it didn’t fail. The access violation is caught in the bowels of lstrcpy, which just fails quietly. This kind of “error handling” is an abomination; while it certainly protects the program from crashing, it also protects the programmer from noticing what is certain to be a bug in the program. It certainly doesn’t protect the program from working incorrectly.

## The Clipboard User Interface

The implementation of the clipboard commands – cut, copy and paste – is straightforward enough. Representing them properly in the user interface is a little trickier:

* Copy should be enabled iff text is selected.
* Cut should be enabled iff text is selected and the file is writeable.
* Paste should be enabled iff the clipboard contains text and the file is writeable.

(Iff, by the way, is shorthand for “if and only if.”) The delete command is grouped with the clipboard commands on the Edit menu; it should be enabled iff the file is writeable and non-empty.

Enabling and disabling menu items is easy. We receive a `WM_INITMENU` message just before the menu opens, and can enable and disable to our heart’s content. The toolbar is another matter. Since it is always visible, we must enable and disable buttons synchronously in response to outside events.

Enabling and disabling of the cut and copy commands is done in Editor::onPosChange, which is called whenever something happens in the edit control, including when the selection changes.

To properly enable and disable the paste command, the TextEdit main window hooks itself into the clipboard viewer chain. Each member of the clipboard viewer chain is responsible for holding the next viewer in the chain; if any application fails to uphold this responsibility, the viewer chain collapses. This design stems from the early days of Windows and is not very robust. Today, this would probably (?) have been designed differently, as it is really asking for trouble.

At any rate, mainwnd.cpp has a static variable `s_hwndNextClipboardViewer` to do the job; it is initialized in onCreate:

```C++
s_hwndNextClipboardViewer = SetClipboardViewer( hwnd );
```

The window is unhooked from the chain again in onDestroy:

```C++
ChangeClipboardChain( hwnd, s_hwndNextClipboardViewer );
```

Once registered as a clipboard viewer, the window receives `WM_DRAWCLIPBOARD` messages whenever the clipboard contents change:

```C++
PRIVATE void onDrawClipboard( HWND hwnd ) {

   if ( IsWindow( s_hwndNextClipboardViewer ) ) {
      FORWARD_WM_DRAWCLIPBOARD( s_hwndNextClipboardViewer, SNDMSG );
   }
   enablePaste( hwnd );
}
```

The **enablePaste** function is responsible for actually enabling and disabling the paste command. Its implementation is trivial; the trick lies in calling it at the right time. The onDrawClipboard function takes care of this.

The hairiest part of clipboard viewerhood is handling someone else’s unhooking from the chain. If the window just below us in the chain – `s_hwndNextClipboardViewer` – is bailing out, we must update the `s_hwndNextClipboardViewer` variable with the next window down the chain. If not, we just forward the `WM_CHANGECBCHAIN` message to `s_hwndNextClipboardViewer`:

```C++
PRIVATE void onChangeCBChain(
    HWND hwnd, HWND hwndRemove, HWND hwndNext )
{
   if ( s_hwndNextClipboardViewer == hwndRemove ) {
      s_hwndNextClipboardViewer = hwndNext;
   } else {
      FORWARD_WM_CHANGECBCHAIN( s_hwndNextClipboardViewer,
         hwndRemove, hwndNext, SNDMSG );
   }
}
```

An interesting experiment is to remove the forwarding of `WM_DRAWCLIPBOARD`, then start the clipboard viewer, then start TextEdit. The clipboard viewer is now essentially blind to changes of the clipboard contents! As I said, the design of the clipboard viewer chain is asking for trouble.

## Persistence in the Main Window

TextEdit stores information about the position and size of the window used to edit a given file. That way, we can restore the window to the same position and size the next time that file is edited. The Editor::saveState method is responsible for – you guessed it – saving the state.

Many applications save state information of one kind or another, and a common approach is to save the state when the application exits. If the application (or the whole system) crashes, the state information is, unfortunately, lost.

TextEdit saves state information for the window whenever said state information has changed. When that happens, we get `WM_SIZE`, `WM_MOVE` or `WM_SYSCOMMAND` messages. The natural thing to do would be to call saveState in response to these messages, but with full-window dragging, this can slow things down so much that the dragging gets noticeably more jerky. To avoid this problem, we start a half-second timer instead, and call saveState in response to the firing of the timer. The timer is reset on every new state-changing message, so state is only saved when the user stops dragging the window or pauses for more than half a second.

Why, I hear you ask, not use `WM_EXITSIZEMOVE` instead of this timer nonsense? This is due to an implementation oddity in Windows. Perhaps I’m even justified in calling it a bug, as I’m fairly sure it was unintentional: If you select one of the window tiling commands from the task bar context menu, `WM_EXITSIZEMOVE` is never sent. I know this to be true under Windows NT 4.0; it may not be true on all versions of Windows. That’s irrelevant in any case; as long as one supported platform misbehaves, we need to handle the problem.

A final detail about full-window dragging: This can cause unsightly flashing of the caret in the edit window. To avoid this, the caret is hidden in response to `WM_ENTERSIZEMOVE` and shown again in response to `WM_EXITSIZEMOVE`. The problem noted above doesn’t apply; when you move or size the window, both `WM_ENTERSIZEMOVE` and `WM_EXITSIZEMOVE` are sent.

Chapter 10 explains how to create persistent variables using the registry. The Document class allows you to create persistent variables on a per-document basis. Window position and window size, for example, are both stored per document.

## Drag and Drop

To support file drag and drop, a window must do three things:

* Call DragAcceptFiles( hwnd, TRUE ) at startup time
* Call DragAcceptFiles( hwnd, FALSE ) at destruction time
* Handle the `WM_DROPFILES` message.

Handling the message is a matter of calling DragQueryFile (perhaps several times), then calling DragFinish. Since TextEdit is an SDI application, we must settle the question of how to handle dropping of multiple files – we obviously can’t open them all in the same application instance. TextEdit solves this in a manner similar to how it opens multiple files on the command line: It takes the first file for itself, and sends the rest to startInstance:

```C++
PRIVATE void onDropFiles( HWND hwnd, HDROP hdrop ) {
   const UINT DRAGQUERY_NUMFILES = (UINT) -1;
   const int nFiles = DragQueryFile( hdrop, DRAGQUERY_NUMFILES, 0, 0 );
   for ( int iFile = nFiles - 1; 0 <= iFile; --iFile ) {
      PATHNAME szDragFile = { 0 };
      verify( 0 < DragQueryFile( hdrop, iFile, szDragFile, dim( szDragFile ) ) );
      if ( 0 == iFile ) {
         Editor *pEditor = getEditor( hwnd );
         pEditor->saveIfNecessary();
         pEditor->openFile( szDragFile );
      } else {
         const String strArg = formatMessage( _T( "\"%1\"" ), szDragFile );
         startInstance( strArg );
      }
   }
   DragFinish( hdrop );
}
```

## Menu Management

TextEdit handles two messages that properly fall under the heading of menu management: `WM_INITMENU` and `WM_MENUSELECT`.

The `WM_INITMENU` message is sent just before a menu drops down, and is intended to let you adjust menu items – enabling, disabling, checking and unchecking are typical chores. Since drop-down menus aren’t visible all the time, it is sufficient to do this just before the menu opens, and usually easier, too. The toolbar is more of a problem. It is always visible, and demands immediate gratification.

In mainwnd.cpp, `WM_INITMENU` is handled by onInitMenu. Aside from enabling and disabling this and that, it also refreshes the MRU (Most Recently Used) file list. The `WM_INITMENU` message is sent for popup menus as well as for window menus, so the exact same function serves to append the MRU file list to the toolbar’s File Open popup menu.

The `WM_MENUSELECT` message is sent when a menu or menu item is highlighted. Note that the `HANDLE_WM_MENUSELECT` macro in windowsx.h has a bug – it doesn’t handle the `MENU_CLOSING` case correctly. For that reason, the macro is redefined in **mainwnd.cpp** (this time correctly).

In mainwnd.cpp, `WM_MENUSELECT` is handled by **onMenuSelect**. The message is handled to update the status bar with a description of the currently highlighted menu item. The Windows function MenuHelp can be used to take the drudgery out of this, but TextEdit doesn’t use it. In the first place, MenuHelp can’t display text for popup menus; in the second place, it doesn’t give you much control over the string to display.

Popup menus don’t, unfortunately, have useful IDs, so when a popup menu comes along, you must somehow figure out which menu it is. The most obvious and simple way to do this is to check the first menu item on the menu. If the first menu item is `ID_FILE_NEW`, for example, you have hold of the File menu. The problem with this approach is that it breaks if you insert a new item at the top of a menu, and it doesn’t handle cascading menus without extra work.

TextEdit uses a different approach; it checks to see if the menu contains – anywhere – a given menu item. This approach is more robust than the first one. Both approaches can run into problems if a menu hierarchy has duplicate entries of the key IDs. One may hope that Microsoft adds IDs to popup menus some day; this feature has always been present in OS/2’s Presentation Manager.

The Editor class has two helper functions that produce menu description strings. One is getMenuDescription, which handles submenus; the other is getMenuItemDescription, which handles menu items. The latter tries its best to be clever, and changes the description depending on whether an item is enabled or disabled, what the current file name is or what the current selection is. This requires some hand coding, but the effect in the user interface is nice.

The menuUtils module defines utility functions for use with menus and menu items. For the most part, these are simple wrappers for Windows functions. The only exception is containsMenuItem, which checks whether a menu or any of its submenus contains a command with a given ID.

[menuUtils.h](../src/menuUtils.h)\
[menuUtils.cpp](../src/menuUtils.cpp)

[Sidebar: Messy Menus, Accelerator Alignment](Sidebar-Messy-Menus.md)

## Communication Between TextEdit Instances

Different instances of TextEdit communicate using the `WM_APP` message. During startup, TextEdit checks to see if an already running instance has a given file loaded; it does this using `WM_APP`. (see the **activateOldInstance** module). The lParam is a global atom representing the file name. `WM_APP` returns 1 if the atom represents the currently loaded file, otherwise 0.

## Changing User Settings

Windows broadcasts `WM_SYSCOLORCHANGE` or `WM_SETTINGCHANGE` messages whenever the user changes the customization of the Windows GUI. Handling `WM_SYSCOLORCHANGE` is straightforward; `WM_SETTINGCHANGE` is more complex. The language may have changed, so the menu bar must be redrawn. Font sizes may have changed; this may require recalculating the layout. The status bar uses the currently defined menu font (see the MenuFont class), and the toolbar uses large icons if the size of the menu font is above a certain threshold.

Many applications, such as the Windows Explorer, don’t change the font in the status bar to reflect changes in the user’s preferences. I find this rather strange.

Even TextEdit doesn’t change the font in the dialogs, sad to say.

## Notifications

The main window does not handle `WM_NOTIFY`. Yet, it does have a toolbar, complete with ToolTips and drop-down menu. Both these features are handled through `WM_NOTIFY`, so what’s going on here?

The toolbar subclasses the main window, that’s what’s going on. It does this a) in order to spy on `WM_SIZE` messages, and b) in order to steal the `WM_NOTIFY` messages. That way, more functionality is encapsulated within the toolbar itself.

## The Editor Connection

The main window’s reference to the Editor object is stored as a window long. The registration of the main window class reserves `MAINWND_EXTRABYTES` extra bytes of storage for each instance.

Given the handle to the main window, the getEditor function retrieves the corresponding Editor object.

[mainwnd.h](../src/mainwnd.h)\
[mainwnd.cpp](../src/mainwnd.cpp)

repository: petterh/textedit

repo_name: petterh/textedit


text:
## Provision a data backend for your service

Tutum offers a large number of data stores in its *Jumpstart* library. From Redis and MongoDB to PostgreSQL and MySQL. In this step you will learn how to add a databackend that your service will use. You'll be creating a Mongo DB, but most concepts will apply to any data backend.

The first step is to provision the data service itself. Execute this to create and run the Mongo service using the [tutum/mongodb](https://github.com/tutumcloud/tutum-docker-mongodb) image:

```
$ tutum service run -e AUTH=no --name mongo tutum/mongodb
```
**--env AUTH=no** defines an environment variable that disables authentication for MongoDB. Because we are not publishing any ports for this service, only services **linked** to your *MongoDB service* will be able to connect to it.

Check to make sure that your *mongo service* is *running*.

```
$ tutum service ps
NAME    UUID      STATUS       #CONTAINERS  IMAGE                                      DEPLOYED        PUBLICDNS
web     1ecbf656  ▶ Running              2  tutum.co/borjaburgos/quickstart-go:latest  1 hour ago      web.borjaburgos.svc.tutum.io
lb      1ca94183  ▶ Running              1  tutum/haproxy:latest                       13 minutes ago  lb.borjaburgos.svc.tutum.io
mongo   59e0f357  ▶ Running              1  tutum/mongodb:latest                       1 minute ago    mongo.borjaburgos.svc.tutum.io
```

### Link the Web (go) service to the Data (mongo) service

```
$ tutum service set --link mongo:mongo --redeploy web
```

Visit or `curl` the load balanced web endpoint again. You'll notice that the *web* service now makes use of the MongoDB data backend, and the *MongoDB Status* shows as **Connected**. Do not that both containers, **web-1** and **web-2**, make use of the same **mongo** service running a single container.

    $ curl lb-1.$TUTUM_USER.cont.tutum.io

hello, Golang users

    Hostname: web-1
MongoDB Status: Connected%
    $ curl lb-1.$TUTUM_USER.cont.tutum.io

hello, Golang users

    Hostname: web-2
MongoDB Status: Connected%
    $ curl lb-1.$TUTUM_USER.cont.tutum.io

hello, Golang users

    Hostname: web-1
MongoDB Status: Connected%
    $ curl lb-1.$TUTUM_USER.cont.tutum.io

hello, Golang users

    Hostname: web-2
MongoDB Status: Connected%

Next: [Service Stacks](https://support.tutum.co/support/solutions/articles/5000539711)

repository: tutumcloud/support-docs

branch_name: refs/heads/staging

repo_name: tutumcloud/support-docs


text:
# go-keypairs

The lightest touch over top of Go's `crypto/ecdsa` and `crypto/rsa` to make them
*typesafe* and to provide JSON Web Key (JWK) support.

# Documentation

Use the source, Luke!

<https://godoc.org/github.com/big-squid/go-keypairs>

# Philosophy

Always remember:

> Don't roll your own crypto.

But also remember:

> Just because you _don't_ know someone doesn't make them smart.

Don't get the two mixed up!

(furthermore, [just because you _do_ know someone doesn't make them _not_ smart](https://www.humancondition.com/asid-prophets-without-honour-in-their-own-home/))

Although I would **not** want to invent my own cryptographic algorithm,
I've read enough source code to know that, for standards I know well,
I feel much more confident in the security, extensibility, and documentation
of tooling that I've write myself.

# Type Safety

Go has _excellent_ crytography support and provides wonderful
primitives for dealing with them. Its Achilles' heel is they're **not typesafe**!

As of Go 1.11.5 `crypto.PublicKey` and `crypto.PrivateKey` are "marker interfaces"
or, in other words, empty interfaces that only serve to document intent without
actually providing a constraint to the type system.

go-keypairs defines `type keypairs.PrivateKey interface { Public() crypto.PublicKey }`,
which is implemented by `crypto/rsa` and `crypto/ecdsa`
(but not `crypto/dsa`, which we really don't care that much about).

Since there are no common methods between `rsa.PublicKey` and `ecdsa.PublicKey`,
go-keypairs lightly wraps each to implement `Thumbprint() string` (part of the JOSE/JWK spec).

# JSON Web Key "codec"

Although there are many, many ways that JWKs could be interpreted
(possibly why they haven't made it into the standard library), go-keypairs
follows the basic pattern of `encoding/x509` to Parse and Marshal
only the most basic and most meaningful parts of a key.

I highly recommend that you use `Thumbprint()` for `KeyID` you also
get the benefit of not losing information when encoding and decoding
between the ASN.1, x509, PEM, and JWK formats.

# LICENSE

Copyright (c) 2018-2019 Big Squid, Inc.

This work is licensed under the terms of the MIT license.
For a copy, see <https://opensource.org/licenses/MIT>.

repository: big-squid/go-keypairs

gha_language: Go

repo_name: big-squid/go-keypairs


text:
# TeamsCode Registration Data

This repository contains registration data from TeamsCode's high school programming contests. The data comes in Excel format and is formatted as follows:

| Size        | Name        | Division    | School      | Language |
| ----------- | ----------- | ----------- | ----------- | ---------|
| 1 | MIHS Programmers | Advanced | Mercer Island High School | Java |
| 3 | Cool team name | Intermediate | Islander Middle School | C++ |

[Click here](./TeamsCode_Registration_Data.zip) to download a zip file of the Excel sheets.

Check out our blog post regarding this data [here](https://teamscode.com/blog/analyzing-registration-data/)!

repository: teamscode/registration-data

repo_name: teamscode/registration-data


text:
---
layout: post
title:  Uncrossed Lines
date:   2020-05-24 03:00 -0700
catalog: false
level:  Medium
number: 1035
lcurl: Uncrossed-Lines
tags:
    - leetcode
    - Python
    - array
    - dp
---
We write the integers of `A` and `B` (in the order they are given) on two separate horizontal lines.

Now, we may draw *connecting lines*: a straight line connecting two numbers `A[i]` and `B[j]` such that:

- `A[i] == B[j]`;
- The line we draw does not intersect any other connecting (non-horizontal) line.

Note that a connecting lines cannot intersect even at the endpoints: each number can only belong to one connecting line.

Return the maximum number of connecting lines we can draw in this way.

**Example 1:**

![img](https://assets.leetcode.com/uploads/2019/04/26/142.png)

```
Input: A = [1,4,2], B = [1,2,4]
Output: 2
Explanation: We can draw 2 uncrossed lines as in the diagram.
We cannot draw 3 uncrossed lines, because the line from A[1]=4 to B[2]=4 will intersect the line from A[2]=2 to B[1]=2.
```

**Example 2:**

```
Input: A = [2,5,1,2,5], B = [10,5,2,1,5,2]
Output: 3
```

**Example 3:**

```
Input: A = [1,3,7,1,7,5], B = [1,9,2,5,1]
Output: 2
```

## Solution

这个题采用动态规划的解法，先初始化dp数组全部为1， 然后初始化第一行和第一列，如果A[i]
中含B[0]，那么在之后的dp[0][i]都初始化为1，因为这说明b[0]可以形成一条线，而且只有一条，同样的道理初始化dp的第一列。
然后从A和B的第二个元素开始调用动态规划转移方程：
如果A[i] == B[j],那么dp[i][j] = 1 + dp[i-1][j-1]
否则 dp[i][j] = max(dp[i-1][j],dp[i][j-1]

```
class Solution:
    def maxUncrossedLines(self, A: List[int], B: List[int]) -> int:
        dp=[[0 for i in range(len(A))] for j in range(len(B))]
        if A[0] ==B[0]:
            dp[0][0] = 1
        for i in range(1,len(A)):
            if B[0]==A[i]:
                dp[0][i] =1
            else:
                dp[0][i]=dp[0][i-1]
        for j in range(1,len(B)):
            if B[j]==A[0]:
                dp[j][0] =1
            else:
                dp[j][0] =dp[j-1][0]
        for i in range(1,len(B)):
            for j in range(1,len(A)):
                if B[i]==A[j]:
                    dp[i][j] = 1+(dp[i-1][j-1])
                else:
                    dp[i][j] = max(dp[i-1][j],dp[i][j-1])
        return dp[-1][-1]
```

## Youtube  视频

<iframe width="560" height="315" src="https://www.youtube.com/embed/jxPHhLCxGFQ" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>


text:
---
layout: post
title: "Chalk5"
description: ""
category: genes
tags: [chalkiness]
---

* **Information**
    + Symbol: Chalk5
    + MSU: [LOC_Os05g06480](http://rice.plantbiology.msu.edu/cgi-bin/ORF_infopage.cgi?orf=LOC_Os05g06480)
    + RAPdb: [Os05g0156900](http://rapdb.dna.affrc.go.jp/viewer/gbrowse_details/irgsp1?name=Os05g0156900)

* **Publication**
    + [Chalk5 encodes a vacuolar H+-translocating pyrophosphatase influencing grain chalkiness in rice](http://www.ncbi.nlm.nih.gov/pubmed?term=Chalk5 encodes a vacuolar H+-translocating pyrophosphatase influencing grain chalkiness in rice%5BTitle%5D), 2014, Nature Genetics.

* **Genbank accession number**
    + [AK107275](http://www.ncbi.nlm.nih.gov/nuccore/AK107275)
    + [KJ363317](http://www.ncbi.nlm.nih.gov/nuccore/KJ363317)
    + [KJ363318](http://www.ncbi.nlm.nih.gov/nuccore/KJ363318)
    + [AK107275](http://www.ncbi.nlm.nih.gov/nuccore/AK107275)
    + [KJ363317](http://www.ncbi.nlm.nih.gov/nuccore/KJ363317)
    + [KJ363318](http://www.ncbi.nlm.nih.gov/nuccore/KJ363318)
    + [AK107275](http://www.ncbi.nlm.nih.gov/nuccore/AK107275)
    + [KJ363317](http://www.ncbi.nlm.nih.gov/nuccore/KJ363317)
    + [KJ363318](http://www.ncbi.nlm.nih.gov/nuccore/KJ363318)

* **Key message**
    + Elevated expression of Chalk5 increases the chalkiness of the endosperm, putatively by disturbing the pH homeostasis of the endomembrane trafficking system in developing seeds, which affects the biogenesis of protein bodies and is coupled with a great increase in small vesicle-like structures, thus forming air spaces among endosperm storage substances and resulting in chalky grain.

* **Connection**

[//]: # * **Key figures**


text:
Jetstream Cashier Billing Portal
================================

![CI](https://github.com/renoki-co/jetstream-cashier-billing-portal/workflows/CI/badge.svg?branch=master)
[![codecov](https://codecov.io/gh/renoki-co/jetstream-cashier-billing-portal/branch/master/graph/badge.svg)](https://codecov.io/gh/renoki-co/jetstream-cashier-billing-portal/branch/master)
[![StyleCI](https://github.styleci.io/repos/320252661/shield?branch=master)](https://github.styleci.io/repos/320252661)
[![Latest Stable Version](https://poser.pugx.org/renoki-co/jetstream-cashier-billing-portal/v/stable)](https://packagist.org/packages/renoki-co/jetstream-cashier-billing-portal)
[![Total Downloads](https://poser.pugx.org/renoki-co/jetstream-cashier-billing-portal/downloads)](https://packagist.org/packages/renoki-co/jetstream-cashier-billing-portal)
[![Monthly Downloads](https://poser.pugx.org/renoki-co/jetstream-cashier-billing-portal/d/monthly)](https://packagist.org/packages/renoki-co/jetstream-cashier-billing-portal)
[![License](https://poser.pugx.org/renoki-co/jetstream-cashier-billing-portal/license)](https://packagist.org/packages/renoki-co/jetstream-cashier-billing-portal)

Jetstream Cashier Billing Portal is a simple Spark alternative written for Laravel Jetstream, with the super-power of tracking plan quotas, like seats or projects number on a per-plan basis. It comes with built-in stacks and design files for easy scaffolding.

**Currently, only Inertia with Stripe are supported. For Livewire, any PR is welcomed!**

![example](example.png)

## 🤝 Supporting

Renoki Co. on GitHub aims on bringing a lot of open source projects and helpful projects to the world. Developing and maintaining projects everyday is a harsh work and tho, we love it.

If you are using your application in your day-to-day job, on presentation demos, hobby projects or even school projects, spread some kind words about our work or sponsor our work. Kind words will touch our chakras and vibe, while the sponsorships will keep the open source projects alive.

[![ko-fi](https://www.ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/R6R42U8CL)

## 🚀 Installation

This package assumes you have installed Jetstream in your project. If not, head over to [Jetstream website](https://jetstream.laravel.com) for installation steps.

### Cashier

Make sure to have prepared your models to use Cashier as explained in the [Cashier documentation](https://laravel.com/docs/8.x/billing), including the billable traits and tables. Jetstream Cashier Billing Portal **WILL NOT** install them for you.

### Scaffolding

You can install the package via composer:

```bash
composer require renoki-co/jetstream-cashier-billing-portal
```

You shall install the Cashier Billing Portal in one command, just like Jetstream. This will install Cashier, Cashier Register and Billing Portal.

```bash
$ php artisan billing-portal:install inertia stripe
```

### Stripe Checkout

The only thing you should do is to add the [Stripe Javascript SDK code](https://stripe.com/docs/js/including) **before** the `app.js` import in your `app.blade.php` file:

```html
<script src="https://js.stripe.com/v3/"></script>
<script src="{{ mix('js/app.js') }}" defer></script>
```

## 🙌 Usage

Jetstream Cashier Billing Portal is written on top of [Cashier Register](https://github.com/renoki-co/cashier-register), a complete plan and usage quota manager for your Laravel application, you are free to follow the [Cashier Register examples](https://github.com/renoki-co/cashier-register) and leverage the true power of billing.

In `CashierRegisterServiceProvider`'s boot method you may define the plans you need, with their features and a quota (a limit of use) for each feature.

Jetstream Cashier Billing Portal will take note of it and will display the plans for your users to subscribe to.

```php
use RenokiCo\CashierRegister\CashierRegisterServiceProvider as BaseServiceProvider;
use RenokiCo\CashierRegister\Saas;

class CashierRegisterServiceProvider extends BaseServiceProvider
{
    /**
     * Boot the service provider.
     *
     * @return void
     */
    public function boot()
    {
        parent::boot();

        Saas::plan('Gold Plan', 'price_...')
            ->monthly(30)
            ->features([
                Saas::feature('Seats', 'seats', 5)->notResettable(),
                Saas::feature('Projects', 'projects')->unlimited()->notResettable(),
            ]);
    }
}
```

### Routes

By default, the subscriptions are accessible under `/billing`, but you can change the `/billing` prefix easily in `config/billing-portal.php`.

For more information about defining plans and quotas, check [Cashier Register documentation](https://github.com/renoki-co/cashier-register) and check [Laravel Cashier for Stripe documentation](https://laravel.com/docs/8.x/billing) on handling the billing.

### Custom Billables

By default, the billing is made directly on the currently authenticated model. In some cases like using billable trait on the Team model, you may change the model that will be retrieved from the current request. You may define it in the `boot()` method of `BillingPortalServiceProvider`:

```php
use Illuminate\Http\Request;
use RenokiCo\BillingPortal\BillingPortal;

class BillingPortalServiceProvider extends BaseServiceProvider
{
    /**
     * Boot the service provider.
     *
     * @return void
     */
    public function boot()
    {
        parent::boot();

        BillingPortal::resolveBillable(function (Request $request) {
            return $request->user()->currentTeam;
        });
    }
}
```

### Modifying the actions

Even if the scaffolding comes with basic controller logic to handle new subscriptions or manage existing ones, you are free to change the Billing Portal's actions in `app/Actions/BillingPortal`.

You just have to re-write your logic in the action classes.

### Proration Between Swaps

By default, Billing Portal prorates the swap between plans. If you wish to not prorate the subscription between swaps, you can specify this in your service provider:

```php
use RenokiCo\BillingPortal\BillingPortal;

class BillingPortalServiceProvider extends BaseServiceProvider
{
    /**
     * Boot the service provider.
     *
     * @return void
     */
    public function boot()
    {
        parent::boot();

        BillingPortal::dontProrateOnSwap();
    }
}
```

## 🐛 Testing

``` bash
vendor/bin/phpunit
```

## 🤝 Contributing

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

## 🔒  Security

If you discover any security related issues, please email<EMAIL_ADDRESS>instead of using the issue tracker.

## 🎉 Credits

- [Alex Renoki](https://github.com/rennokki)
- [All Contributors](../../contributors)


text:
# Pokemon-webapp
Web application for test

## Demo

[Watch the LIVE project ](https://pokemoon.netlify.app/)

![Pokemon web app home](https://github.com/zefe/pokemon-frontend/blob/main/src/assets/images/home.png)

## Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Clone this repo

```
git clone https://github.com/zefe/pokemon-frontend.git
```

### Prerequisites

What things you need to install the software and how to install them

### This project is built with

Node v12.18.4 & npm 6.14.6

### Check that you have node and npm installed

```
node -v
```

```
npm -v
```
[To Install Node.js, npm, and stay up-to-date.](https://www.npmjs.com/get-npm)

### Installing dependencies

Installing dependencies

```
yarn
```

o

```
yarn install
```

run development environment

```
yarn start:dev
```

run production environment

```
yarn start:prod
```

compile the project
```
yarn build
```

[These are some of the most common commands you will need using yarn.](https://classic.yarnpkg.com/en/docs/usage)

repository: zefe/pokemon-frontend

gha_language: JavaScript

repo_name: zefe/pokemon-frontend


text:
---
layout: default
---

# 1994-12-08 - Re: Moto Secure Clear digital?

## Header Data

From: Jonathan Cooper<EMAIL_ADDRESS>To: Wes Felter<EMAIL_ADDRESS>Message Hash: f7110b0485610ed14996cc38c96c98e03470f8ed3219a08bf6caa4e0bf2b7956

Message ID: \<Pine.SV<IP_ADDRESS>1208003600.4295D-100000@xcalibur\>

Reply To<EMAIL_ADDRESS>UTC Datetime: 1994-12-08 05:44:30 UTC

Raw Date: Wed, 7 Dec 94 21:44:30 PST

## Raw message

```
{% raw  %}From: Jonathan Cooper<EMAIL_ADDRESS>Date: Wed, 7 Dec 94 21:44:30 PST
To: Wes Felter<EMAIL_ADDRESS>Subject: Re: Moto Secure Clear digital?
In-Reply-To<EMAIL_ADDRESS>Message-ID: <Pine.SV<IP_ADDRESS>1208003600.4295D-100000@xcalibur>
MIME-Version: 1.0
Content-Type: text/plain

> I just got a second phone line, and decided that if I was going to get a 2-line
> phone it might as well be a good one, so I am considering a Motorola Secure
> Clear cordless 2-line phone with speakerphone. This will be quite an investment,so I was wondering whether the Secure Clear phones are digitally encrypted or
> merely scrambled using some analog method. Anybody know about this? How secure
> are these phones really? --Wes

   As I understand it the system is a cheezy form of frequency
inversion.  It'll stop your neighbors with a scanner, but that's about it.

-jon

( --------[ Jonathan D. Cooper ]--------[<EMAIL_ADDRESS>]-------- )
( PGP 2.6.2 keyprint: 31 50 8F 82 B9 79 ED C4  5B 12 A0 35 E0 9B C0 01 )

{% endraw %}
```

## Thread

+ Return to [December 1994](/archive/1994/12)

+ Return to "[Jonathan Cooper <entropy@IntNet.net>](/authors/jonathan_cooper_entropy_at_intnet_net_)"
+ Return to "[Michael  Conlen <meconlen@IntNet.net>](/authors/michael_conlen_meconlen_at_intnet_net_)"
+ Return to "[Wes Felter <wesf@unicycle.cs.tulane.edu>](/authors/wes_felter_wesf_at_unicycle_cs_tulane_edu_)"

+ 1994-12-04 (Sat, 3 Dec 94 20:24:55 PST) - [Moto Secure Clear digital?](/archive/1994/12/d59072e25f85282e182bff4e3416624d47ab966575e559eb5f71a22b2679f6e2) - _Wes Felter<EMAIL_ADDRESS>  + 1994-12-08 (Wed, 7 Dec 94 21:44:30 PST) - Re: Moto Secure Clear digital? - _Jonathan Cooper<EMAIL_ADDRESS>    + 1994-12-08 (Thu, 8 Dec 94 07:50:17 PST) - [Re: Moto Secure Clear digital?](/archive/1994/12/73b39f76e33e7050067254e8556eaab1d38885125794b98bc02aba8198aaeb82) - _Michael  Conlen<EMAIL_ADDRESS>


text:
Title: Build Log: Height Chart
date: 2019-11-03 06:00
updated: 2019-11-03 06:00
authors: Matthew Kudija
comments: true
slug: height-chart
tags: build log, wood, height, kids

<!-- PELICAN_BEGIN_SUMMARY -->
![alt]({static}../images/height-chart/height-chart1.jpg)

My wife came across an idea of a [height chart](https://abeautifulmess.com/2019/10/wooden-height-chart-diy.html) for measuring the kids and this was a fun afternoon project.

<!-- PELICAN_END_SUMMARY -->

## Materials Required

| Material | Quantity | Description |
| -------- | -------- | ----------- |
| **1 x 1 x 6' pine board** | 1 | Base board |
| **Numbers** | 5 | As desired |
| **Wipe-On Poly** | 3 coats | [Miniwax Wipe-On Poly](https://www.amazon.com/Minwax-40900-Oil-Based-Polyurethane-Finish/dp/B01M1EDG7Y/ref=sr_1_5?keywords=miniwax+wipe-on+poly&qid=1569712857&sr=8-5) |
| **Brown paper bag** | As required | Between coats of poly |
| **Sandpaper** | As required | 220 and 400 grit |
| **Black screws** | 10 | Optional |
| **Drywall anchors** | 2 | [This style](https://www.lowes.com/pd/Blue-Hawk-4-Pack-1-3-4-in-x-1-8-in-Dia-Mini-Drywall-Anchor-Screws-Included/3415978) |

## Tools Required
- Miter saw
- Electric drill
- Square
- Tape measure
- Router with 1/4" straight bit and round-over bit
- Sharpie

### Notes

I bought a nice pine 1 x 6 x 6' board at Lowes. In addition to the unfinished lumber they have a decent selection of finished maple, oak, and pine.

![alt]({static}../images/height-chart/height-chart3.jpg)

The first step was to cut the slots for the foot markers. I used a straight 1/4" router bit and cut to a depth of about 1/8" or 3/16". To help make the cuts quick and consistent, I made a jig with two pieces of scrap wood held together with a clamp to serve as a guide for the router. This make for a quick process of marking and then cutting all 5 slots. Blue masking tape really helps minimize tear-out, and I went over any rough areas with 400 grit sandpaper.

I then used a [Sharpie pro](https://www.amazon.com/Sharpie-Permanent-Marker-Point-2018321/dp/B07DPMKZ8G/ref=sr_1_4?keywords=sharpie+pro&qid=1572828537&sr=8-4) to color each slot, being careful to not let the marker touch the upper edges since it will bleed. Shallower slots help with this process.

Next I used a [round over bit](https://www.amazon.com/gp/product/B07D8R3F7K/ref=ppx_yo_dt_b_asin_title_o05_s00?ie=UTF8&psc=1) to make a nice smooth edge along the perimeter of the board.

For finish, I applied 3 coats of wipe-on poly. After it was dry, I rubbed the whole board down with a piece of cardboard to knock down any high spots from the finish.

![alt]({static}../images/height-chart/height-chart2.jpg)

Next it was time to mount the numbers. I got small black screws to use instead of the nails provided with the numbers. After drilling clearance holes for the screws, I mounted numbers 3, 4, and 5.

The hang the chart I used two drywall anchors hidden under numbers 2 and 6. This was the main reason for using screws to mount the numbers so that they are easily removed if I ever want to remove the chart from the wall. After mounting to the wall, I installed numbers 2 and 6 to complete the project.

![alt]({static}../images/height-chart/height-chart4.jpg)

repository: mohdashifkhan/blog

repo_name: mohdashifkhan/blog


text:
# fs2 data
[![Build Status](https://travis-ci.com/satabin/fs2-data.svg?branch=master)](https://travis-ci.com/satabin/fs2-data) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/920976dd1972483686e02184462f8f17)](https://www.codacy.com/app/satabin/fs2-data?utm_source=github.com&utm_medium=referral&utm_content=satabin/fs2-data&utm_campaign=Badge_Grade) [![Gitter](https://badges.gitter.im/fs2-data/general.svg)](https://gitter.im/fs2-data/general?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)

A set of streaming data parsers based on [fs2][fs2].

For more details and documentation, please visit [the website][website]

## Development

This project builds using [mill][mill]. You can install `mill` yourself or use the provided `millw` wrapper, in this case replace `mill` with `./millw` in the following commands:
* compile everything: `mill __.compile`
* compile & run all tests: `mill __.test`
* run benchmarks (you can provide [JMH][jmh] arguments in the end): `mill '__.benchmarks[2.13.2].runJmh'`

[fs2]: https://fs2.io/
[mill]: https://github.com/lihaoyi/mill
[jmh]: https://openjdk.java.net/projects/code-tools/jmh/
[website]: https://fs2-data.gnieh.org


text:
# Droparea.js

[![Latest Version](https://img.shields.io/github/release/rogeriotaques/droparea.svg)](https://github.com/rogeriotaques/droparea/releases)

Creates an simple, but powerfull area for drag and drop files to upload, falling back to the traditional select method when the user click on it, yet empowered by the auto preview from the selected file.

Inspired on the solution given by Ravishanker Kusuma (http://twitter.com/hayageek)
at http://hayageek.com/drag-and-drop-file-upload-jquery/, which describes how to create a way drag and drop files and upload it to the server.

## [Live Demo](https://rogeriotaques.github.io/droparea/) here

> Note: This file is about Droparea.js from version `2.0.0`. If you are looking for the docs from version `1.0.7`, please refer to [this file](https://github.com/rogeriotaques/droparea/blob/master/readme-1.0.7.md).

## Dependencies

* jQuery 2.1.3 or later

## Getting started

Add the following block of code to the `HEAD` of your page. Remember that the path should be adjusted for the path to wherever you decide place the source files.

```html
    <!-- Import jQuery -->
    <script type="text/javascript" src="//code.jquery.com/jquery-2.1.3.min.js"></script>

    <!-- Import Droparea.js -->
    <link rel="stylesheet" type="text/css" href="path/to/src/droparea.css" media="screen" >
    <script type="text/javascript" src="path/to/src/droparea.min.js"></script>
```

Within the `BODY` tag, create the area where files are gonna be dropped, and the input file for the fallback. You can simply copy and paste the code block below:

```html
    <div class="droparea" >
        <span >Drag and drop files here!</span>
        <img src="http://placehold.it/200" id="file-preview" >
    </div>

    <input type="file" name="file" id="file" accept="image/*" style="display: none;" >
```

Now, all we need is create an instance of the Droparea.js, just like shown below. For your convenience, you can simply copy and paste the code block below:

```html
    <script type="text/javascript" >
      $(document).ready(function(){
        $('.droparea').droparea();
      });
    </script>
```

This will automatically create a droppable area in your page. Easy, right?

## Options

Even though Droparea.js works well with its standard settings, it can be customized to better fit on your project. You may pass the `options` to the plugin as follows:

```javascript
    var opts = { ... }; // see the options below.
    $('.droparea').droparea(opts);
```

### Available options

| Option              | Type       | Default                                                      | Definition                                                                                |
| ------------------- | ---------- | ------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| url                 | `string`   | `N/A`                                                        | Server-side script address.                                                                                |
| method              | `string`   | `'POST'`                                                     | Define the method that droparea.js will use to call the `url`. Possible options are `POST`, `PATCH` or `PUT`.                                                                                |
| upload              | `boolean`  | `true`                                                       | If `false`, droparea.js won't call the URL, but force the user to select the file. If `false`, a `fileHolder` is required                                                                                |
| fileHolder          | `string`   | `'#file'`                                                    | It is the file holder to place files when `upload` is set to `false`. Ignored when `upload` is set to `true`.                                                                                |
| filePreview         | `string`   | `'#file_preview'`                                            | When uploading an image file, and `filePreview` is given, droparea.js tries to intercept the manual selection of files on `fileHolder` and display the selected image on `filePreview` as soon as it is selected. |
| notificationDelay   | `number`   | `5000`                                                       | How long (milliseconds) droparea.js will keep the notification block overflowing the droppable area.                                                                                |
| accepted            | `string`   | `.jpg`|`.png`|`.gif`                               | The accepted extensions for uploaded files. If set `null` or `false` allow all files.                                                                                |
| fileMaxSize         | `number`   | `2048`                                                       | The file maximum size allowed for the uploaded file.                                                                                |
| extra               | `array`    | `[]`                                                         | All the extra data that should be submitted with the file. Push to this array all ids from form elements to be submitted.                                                                                |
| i18n                | `object`   | \* See below                                                 | The internationalization object containing all used strings for translating the existing messages.                                                                                |
| i18n.unableToUpload | `string`   | Unable to upload at this time.
Select a file.      |
| i18n.wrongFileType  | `string`   | Unacceptable file type!
Try: %s                    | `%s` will be replaced by option `accepted` value.                                                                                |
| i18n.wrongFileDize  | `string`   | Dropped file is too big!
Max file size allowed: %s | `%s` will be replaced by option `fileMaxSize` value.                                                                                |
| i18n.abort          | `string`   | Abort                                                        |
| i18n.mb             | `string`   |  MB                                                     |
| i18n.kb             | `string`   |  KB                                                     |
| i18n.percent        | `string`   | %                                                            |
| i18n.dismiss        | `string`   | Dismiss                                                      |
| i18n.error          | `string`   | Err                                                          |
| onSuccess           | `function` | `null`                                                       | Called after the upload succeed. Three arguments are passed: `server_response`, `file_name` and `file`.                                                                                |
| onFail              | `function` | `null`                                                       | Called after the upload fail. One argument is passed: `server_response`.                                                                                |

## Contributions

Feel free to contribute with this project by either suggesting improvements ou bug fixes at the [Issues Page](https://github.com/rogeriotaques/droparea/issues) or forking this repository and submitting [Pull Requests](https://github.com/rogeriotaques/droparea/pulls) (prefered).

I will be more than happy to review and answer all comments and requests, however it may take a few days due to my lack and overload in other projects.

Happy coding! :)

repository: rogeriotaques/droparea

repo_name: rogeriotaques/droparea


text:
## Contributing

We welcome all contributions!  Please head to [issues](https://github.com/Sage-Bionetworks/challengeutils/issues) to either file any bugs/feature requests or find a task you want to assist with.  Make sure to assign yourself the task if you decide to work on it.

### Fork and clone this repository

See the [Github docs](https://help.github.com/articles/fork-a-repo/) for how to make a copy (a fork) of a repository to your own Github account.

Then, [clone the repository](https://help.github.com/articles/cloning-a-repository/) to your local machine so you can begin making changes.

Add this repository as an [upstream remote](https://help.github.com/en/articles/configuring-a-remote-for-a-fork) on your local git repository so that you are able to fetch the latest commits.

On your local machine make sure you have the latest version of the `develop` branch:

```
git checkout develop
git pull upstream develop
```

### Install development dependencies
This will install all the dependencies of the package including the active branch of `challengeutils`.

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

### The development life cycle

1. Pull the latest content from the `develop` branch of this central repository (not your fork).
1. Create a feature branch which off the `develop` branch. If there is a GitHub issue that you are addressing, name the branch after the issue with some more detail (like `issue-123-add-some-new-feature`).
1. After completing work and testing locally (see below), push to your fork.
1. In Github, create a pull request from the feature branch of your fork to the `develop` branch of the central repository.

> *A code maintainer must review and accept your pull request.* A code review (which happens with both the contributor and the reviewer present) is required for contributing. This can be performed remotely (e.g., Skype, Hangout, or other video or phone conference).

This package uses [semantic versioning](https://semver.org/) for releasing new versions. The version should be updated on the `develop` branch as changes are reviewed and merged in by a code maintainer. The version for the package is maintained in the [challengeutils/__version__.py](challengeutils/__version__.py) file.  A github release should also occur every time `develop` is pushed into `main` and it should match the version for the package.

### Testing

Please add tests for new code. These might include unit tests (to test specific functionality of code that was added to support fixing the bug or feature), integration tests (to test that the feature is usable - e.g., it should have complete the expected behavior as reported in the feature request or bug report), or both.

This package uses [`pytest`](https://pytest.org/en/latest/) to run tests. The test code is located in the [test](./test) subdirectory.

Here's how to run the test suite:

```
pytest -vs tests/
```

Tests are also run automatically by Github Actions on any pull request and are required to pass before merging.

### Documentation

`challengeutils` uses [Google style Python docstrings](https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html).  All functions you add must abide by these standards.  The Documentation of each python module can be found in `docs/python` folder and are auto generated by `sphinx`.  If you are adding a new module, you must add to a `.rst` file into this folder.  If you are adding or modifying a command line client function, you must add/modify the files in `docs/client`.

To build documentation:

```
cd docs
make html
open _build/html/index.html
```

### Release Procedure (For Package Maintainers)

* Always merge all new features into `develop` branch first (unless it is a documentation, readme, or github action patch into `main`)
* After initial features are ready in the `develop` branch, create a `release-X.X` branch to prepare for the release.
    * update `challengeutils/__version__.py`
    * update `docs/conf.py` version variable
    * update `docs/about/changelog.md` with release information
* Merge `release-X.X` branch into `main`
* Check documentation build for docs: https://sage-bionetworks.github.io/challengeutils/
* Create release tag (`v...`) and include release notes.  Also include any known bugs for each release here.

repository: Sage-Bionetworks/challengeutils

branch_name: refs/heads/develop

gha_language: Python

repo_name: Sage-Bionetworks/challengeutils


text:
# NorthwindTraders

Northwind Traders is a sample application built using ASP.NET Core and Entity Framework Core. The architecture and design of the project is explained in the video:

* [Clean Architecture with ASP.NET Core 2.1](https://youtu.be/_lwCVE_XgqI) ([slide deck](https://github.com/JasonGT/NorthwindTraders/raw/master/Slides.pdf))

The initial construction of this project is explained in the following blog posts:

* [Code: Northwind Traders with Entity Framework Core](http://www.codingflow.net/northwind-traders-with-entity-framework-core/)
* [Create Northwind Traders Code First with Entity Framework Core – Part 1](http://www.codingflow.net/create-northwind-traders-code-first-with-entity-framework-core-part-1/)
* [Create Northwind Traders Code First with Entity Framework Core – Part 2](http://www.codingflow.net/create-northwind-traders-code-first-with-entity-framework-core-part-2/)

For information on upcoming features and fixes, take a look at the [product roadmap](https://github.com/JasonGT/NorthwindTraders/wiki/Roadmap).

## Getting Started
Use these instructions to get the project up and running.

### Prerequisites
You will need the following tools:

* [Visual Studio Code or 2017](https://www.visualstudio.com/downloads/)
* [.NET Core SDK 2.2](https://www.microsoft.com/net/download/dotnet-core/2.2)
 * [Node.js](https://nodejs.org/en/) (version 10 or later) with npm (version 6.9.0 or later)

### Setup
Follow these steps to get your development environment set up:

  1. Clone the repository
  2. At the root directory, restore required packages by running:
     ```
     dotnet restore
     ```
  3. Next, build the solution by running:
     ```
     dotnet build
     ```
  4. Next, within the `Northwind.WebUI\ClientApp` directory, launch the front end by running:
     ```
     npm start
     ```
  5. Once the front end has started, within the `Northwind.WebUI` directory, launch the back end by running:
     ```
	 dotnet run
	 ```
  5. Launch [http://localhost:52468/](http://localhost:52468/) in your browser to view the Web UI

  6. Launch [http://localhost:52468/api](http://localhost:52468/api) in your browser to view the API

## Technologies
* .NET Core 2.2
* ASP.NET Core 2.2
* Entity Framework Core 2.2

## License

This project is licensed under the MIT License - see the [LICENSE.md](https://github.com/JasonGT/NorthwindTraders/blob/master/LICENSE.md) file for details.

repository: Steve-Tighe/NorthwindTraders

gha_language: C#

repo_name: Steve-Tighe/NorthwindTraders


text:
# Rationale

Kubernetes is today's probably the most promising container orchestration platform and it is gaining huge momentum. There are many different installation tools and hosted solutions:

* [Kubespray](https://github.com/kubernetes-incubator/kubespray)
* [Kubeadm](https://kubernetes.io/docs/setup/independent/create-cluster-kubeadm/)
* [Kubernetes Salt formula](https://github.com/salt-formulas/salt-formula-kubernetes)

* [Google Container engine](https://cloud.google.com/container-engine)
* [Azure Container Service](https://azure.microsoft.com/en-us/services/container-service/)

There is no need to develop new installation method because we already have many sufficient solutions and Kubernetes instllation isn't a rocket science.
However, there are still customers strugling to integrate Kubernetes because of missing solution for complex orchestration of multiple clusters. In this document we aim to address these problems and propose architecture.

## User stories

I'm application **developer** and I'd like to have a tool to quickly spin-up the cluster and run my application on it. I have multiple applications and need to have multiple clusters for different application. It would be nice to have a possibility to run diffirent application versions in on cluster.

I'm KaaS administration and I need be able to manage all the clusters for our internal customers. I need to list then, control resources and get basic overview about each cluster.  Autoscaling clusters (with predefined range) would be a nice bonus.

## Architecture

We have one central backend service (called *queen*) and this service listens for user requests (via API) and can orchestrate and operate clusters.

### Required actions - MVP

* **Create cluster** - This action will be used to deploy new clusters. However, *queen* service don't deploy cluster on it's own but I uses another service (Jenkins, GKE, ..) to create this cluster.
* **Read cluster information** - Read information about new (and existing) cluster and provide this information to users and administrators. This information must include endpoint for Kubernetes API server and all required credentials (token, basic auth or certificates)
* **Deploy application** - This will connect to cluster and deploy the application. TODO: define format (apply YAMLs, Helm, ...)
* **Delete cluster** - destroy the cluster

### Additional actions

* **Check** - read cluster information and give information about node usage and running workload
* **Scale** - add or remove minions
* **Backup** - backup resources in cluster and provide guidance for PV backup
* **Update** - install newer version of Kubernetes
* **Autoscale** - watch Kubernetes scheduler or pods and start new minions when all existing minions are fully utilized
* **Manage addons** - enable or disable cluster addons

repository: mathias-dietrich/kqueen

repo_name: mathias-dietrich/kqueen


text:
---
date: 2020-08-20
title: Scrum Roles
categories:
  - development-team
description: "Understanding and Applying Scrum"
type: Document
---
#### How Many Scrum Teams Should You Be On?
This [video](https://www.scrum.org/resources/blog/how-many-scrum-teams-should-you-be) explores the math behind what it means to be on more than one Scrum Team, and the importance of the Scrum Value, Focus.

#### How Do the 3 Scrum Roles Promote Self-Organisation?
This [blog](https://www.scrum.org/resources/blog/how-do-3-scrum-roles-promote-self-organization) explores the accountability of each Scrum Team role and how they complement each other.

#### Equality - The Roles in Scrum
This [blog](https://www.scrum.org/resources/blog/equality-roles-scrum) focuses on the three roles defined by Scrum and why it is important not to leave any of them out.

repository: IamJackReed/base

repo_name: IamJackReed/base


text:
### Motivation

Test the Harvard MOC cluster against the test shell script and document the process.

### Pre-Requisite

Host Machine: Mac OSX
VM -> Linux Trusty
VM installed using Vagrant + VirtualBox

Ensure you have access to moc-ssh-gateway on your host machine.

#### Install Ubuntu using Vagrant
Create a directory in which you would create a vagrant machine.

    $ mkdir vagrant

Another directory to label for what purpose you are creating the machine.

    $ mkdir test-moc
    $ cd vagrant/test-moc/

You can view a list of vagrant machines at this link or you can create vagrant box:
[vagrant machines](https://atlas.hashicorp.com/boxes/search)
Run the following cmds to setup vagrant machine in lets say terminal 1.

    $ vagrant init ubuntu/trusty64
    $ vagrant up

In a new terminal - term 2:

    $ vagrant ssh
    $ ping <IP_ADDRESS>  // checking of you can access outside network(the network config is NAT enabled)
    $ exit

Back in terminal -1, lets halt the vm as to configure the vagrant file:

   $ vagrant halt

Edit the Vagrant file to attach an IP address to your newly created vm:

    Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
        config.vm.network "private_network", ip: "<IP_ADDRESS>"
    end

#### Enable ssh forwarding for Vagrant

Edit the ssh config file on your host machine:

    $ emacs ~/.ssh/config

Add the following Host info to your config file. This will enable ssh agent
forwarding with vagrant.

    Host vm-ip
        ForwardAgent yes

where vm-ip in my case is "<IP_ADDRESS>".

Run the following ssh command to add the new identity:

    $ ssh-add

Edit the Vagrant file and uncomment the following line:

    config.ssh.forward_agent = true

Launch and login to vagrant machine on another terminal.
At this point running the following command on both the host machine and the vagrant machine.

    $ ssh-add -L

The above command should list the key identities(should be same on both the machines).

### How To tunnel openstack calls through moc ssh gateway

#### Install proxychains

Run the following commands on your vm ,in this example the vbox vm

    $ apt-get install proxychains
    $ vim /etc/proxychains.conf

    - // Comment out existing socks line at the end of file
    socks5 <IP_ADDRESS> 8000  //add this line

    The above config will tunnel commands run with "proxychains" through port 8000 on the local host.

#### Install OpenStack Python client libraries.

    In your vm install openstack python client:
    $ sudo apt-get install python-openstackclient

    // Some of the core packages installed will be listed at the end of installation:

    Setting up python-cinderclient (1:1.0.8-0ubuntu2) ...
    Setting up python-cliff (1.4.5-1ubuntu2) ...
    Setting up python-netaddr (0.7.10-1ubuntu1.1) ...
    Setting up python-iso8601 (0.1.10-0ubuntu1) ...
    Setting up python-novaclient (1:2.17.0-0ubuntu1) ...
    Setting up python-keystoneclient (1:0.7.1-ubuntu1) ...
    Setting up python-glanceclient (1:0.12.0-0ubuntu1) ...
    Setting up python-openstackclient (0.3.0-1ubuntu1) ...
    Setting up python-cliff-doc (1.4.5-1ubuntu2) ...

  Lets refer this page [OpenStack CLI clients](http://docs.openstack.org/user-guide/content/install_clients.html)
  and install the other openstack client libraries required for testing.

    $ apt-get install python-ceilometerclient
    $ apt-get install python-heatclient
    $ apt-get install python-neutronclient
    $ apt-get install python-swiftclient

#### Set up the test script for testing
Copy the test files openstack_test.sh and george.yaml from [harvard cluster wiki](Harvard-Cluster.html) in a new folder inside your vagrant box/vm.

Change permission level for the test script

    $ chmod +x openstack_test.sh

### Steps to run openstack client api's using proxychain against the Cluster

One another terminal:

    $ ssh -D 8000 -N<EMAIL_ADDRESS>
Note: the commands in test script to test volume need to be uncommented.
Lets start testing !

    $ proxychains ./openstack.sh
    The output should looks like the follows:
     |S-chain|-<>-<IP_ADDRESS>:8000-<><>-<IP_ADDRESS>:35357-<><>-OK
     |S-chain|-<>-<IP_ADDRESS>:8000-<><>-<IP_ADDRESS>:9696-<><>-OK....
     // The first time you would get the following message and have a bash shell to interact with.
     Test server at <IP_ADDRESS> now. There should be a volume attached.
     $
     // Wait for a minute and then try to ssh into the vm which is cirros in this case.
     $ ssh<EMAIL_ADDRESS>-i /tmp/testkey.pem

     // You will get the following output:
     The authenticity of host '<IP_ADDRESS> (<IP_ADDRESS>)' can't be established.
     RSA key fingerprint is d7:51:df:e1:f8:4e:77:b1:29:f0:38:ae:da:da:40:07.
     Are you sure you want to continue connecting (yes/no)? "yes"
     $ "exit"  //type exit to go back the bash shell of the running script
     vagrant@vagrant-ubuntu-trusty-64:~/lets-test$ "exit"   //type exit again to continue the script
     // The script might halt again after detaching the volume from the previous instance and prompt the
     // following:
     Test server at <IP_ADDRESS> now.
     vagrant@vagrant-ubuntu-trusty-64:~/lets-test$
     Note: You can execute the openstack CLI like following:
     vagrant@vagrant-ubuntu-trusty-64:~/lets-test$ proxychains nova list
     // Look under References at the end of page to refer to the cheat sheet for cmds.

     The Heat manifest sets up two servers.
     Test your heat stack now

     vagrant@vagrant-ubuntu-trusty-64:~/lets-test$ proxychains nova list
     ProxyChains-3.1 (http://proxychains.sf.net)
     |S-chain|-<>-<IP_ADDRESS>:8000-<><>-<IP_ADDRESS>:35357-<><>-OK
     |S-chain|-<>-<IP_ADDRESS>:8000-<><>-<IP_ADDRESS>:8774-<><>-OK

  continuation ....

`| ID                                 | Name    | Status | Task State | Power State | Networks|`

`|376a149b-363c-46c7-a3d5-37065d769f38| Server1 | ACTIVE | - | Running  | borr=<IP_ADDRESS>, <IP_ADDRESS> |`

`|747d96b4-9169-423c-a084-77a4b22b94ac| Server2 | ACTIVE | - | Running  | borr=<IP_ADDRESS>, <IP_ADDRESS> |`

    // Wait for few minutes before you test the new instances Server1 and Server2 and then type "exit" to continue
    // the testing.

    vagrant@vagrant-ubuntu-trusty-64:~/lets-test$ "exit"

    // The script would clean up the resources created.
    Done !!

Testing is Complete !

#### References

[OpenStack CLI cheat sheet](http://docs.openstack.org/user-guide/content/app_cheat_sheet.html)

repository: sshyran/documentation

repo_name: sshyran/documentation


text:
# Environment variables / System properties / App properties are partially or fully masked

In some cases, the values we get back from Actuator are intentionally masked and get sent back as **\*\*\*\*\*\*.** This is caused by configuration on the service end.

Example of a heavily redacted System Properties

### Spring Boot 2.X

Spring Boot 2.X masks keys with the following patterns by default:

* `password`
* `secret`
* `key`
* `token`
* `.*credentials.*`
* `vcap_services`

These patterns can be set using the following properties ([Reference](https://docs.spring.io/spring-boot/docs/1.5.22.RELEASE/reference/html/howto-actuator.html#howto-sanitize-sensible-values)):

* `endpoints.configprops.keys-to-sanitize=comma,delimited,list`
* `endpoints.env.keys-to-sanitize=comma,delimited,list`

### Spring Boot 3.X

In Spring Boot 3.X, all values are masked by default. If this behavior is not desired, it can be controlled using by setting the following properties to either `always`  (Not recommended) or `when-authorized` and setting Ostara to authenticate with your application ([Reference](https://docs.spring.io/spring-boot/docs/current/reference/html/application-properties.html#appendix.application-properties)):

* `management.endpoint.configprops.show-values={always|when-authorized|never}`
* `management.endpoint.env.show-values={always|when-authorized|never}`

repository: krud-dev/ostara

gha_language: TypeScript

repo_name: krud-dev/ostara


text:
# Virtru SDK Google Apps Script Samples
Google Apps Script samples for the [Virtru Platform SDK](https://developer.virtru.com/)

## Documentation
- [How it Works](https://developer.virtru.com/docs/how-it-works)
- [Authentication](https://developer.virtru.com/docs/how-to-add-authentication)
- [Virtru JS SDK](https://docs.developer.virtru.com/js/latest/)

## Samples
- [Google Doc Encrypt & Share](./virtru-encrypt-google-doc)

## License
Copyright © 2019 Virtru Corporation

This repository is released under the MIT license for all artifacts in this repository, with the following exceptions which are subject to our [Virtru Data Protection Platform Subscription Agreement](https://www.virtru.com/terms-of-service/):

- virtru-sdk

repository: virtru/virtru-sdk-samples-gas

repo_name: virtru/virtru-sdk-samples-gas


text:
Vim for C++ Projects

Watching C++ vim gurus like Chandler Carruth and Manuel Klimek you can get the impression that all there is to it is installing YouCompleteMe and CtrlP and you have a full fledged C++ IDE... sadly it is not that simple :)

## The Tools

* YouCompleteMe
* CtrlP
* Silver searcher

### What you need to do

### Caveats, Warnings etc

* YouCompleteMe does *not* index your project. It indexes the files you open. This means for instance that while there is a "Go to Definition" command, it rarely works, since while code using a symbol needs access to the *declaration* in the proper include file, the *definition* should hopefully lie in a separate cpp file that is *not* know by the current cpp file.
*

license: Unlicense


text:
# dd

This package will add the `dd` and `dump` helpers to your Phalcon application.

## Install

Run:

```bash
composer require phalcongelist/dd
```

## Copyright

This project is open source software licensed under the New BSD License.
See the LICENSE file for more. © 2016-2017, Phalcon Team

repository: Keis-Team/keis

repo_name: Keis-Team/keis


text:
How to set up the CD and DVD drives
===================================

**1.** Plug them into a USB hub, and plug that into the computer. Test each drive and make note of each drive's letter for later.

**2.** Go to the "software" folder in tutorials/computer and read the tutorial under "start", then under "drives".

repository: milkey-mouse/watson

repo_name: milkey-mouse/watson


text:
![logo](https://cloud.githubusercontent.com/assets/22377058/24007440/388ef8d0-0a77-11e7-8419-ac21789b792e.png)

[![CI Status](http://img.shields.io/travis/VihlayewAlex/SWGraphs.svg?style=flat)](https://travis-ci.org/VihlayewAlex/SWGraphs)
[![Version](https://img.shields.io/cocoapods/v/SWGraphs.svg?style=flat)](http://cocoapods.org/pods/SWGraphs)
[![License](https://img.shields.io/cocoapods/l/SWGraphs.svg?style=flat)](http://cocoapods.org/pods/SWGraphs)
[![Platform](https://img.shields.io/cocoapods/p/SWGraphs.svg?style=flat)](http://cocoapods.org/pods/SWGraphs)

SWGraphs is a graph data structure, operations and algorithms library, written with Swift.

## Example

To run the example project, clone the repo, and run `pod install` from the Example directory first.

## Requirements

SWGraph requires Swift 3 support. (Xcode 8+)

## Installation

SWGraphs is available through [CocoaPods](http://cocoapods.org). To install
it, simply add the following line to your Podfile:

```ruby
pod "SWGraphs"
```

## Usage

### Import
Don't forget to add import:
```swift
import SWGraphs
```

### Graphs

#### Initializing with incidence matrix
More about incidence matrixes on [Wikipedia](https://en.wikipedia.org/wiki/Incidence_matrix).
```swift
let incidenceMatrix = [ [1,0,-1,1],
                        [-1,1,0,0],
                        [0,-1,1,0],
                        [0,0,0,-1] ]
let graph = SWGGraph(with: incidenceMatrix)
```
#### Graph types
Every graph have it's type, defined as `SWGGraphType`:
```swift
public enum SWGGraphType {
    case Oriented
    case Unoriented
}
```
Notice that type is get-only property so it can not be changed manually.

#### Graph properties
Radius:
```swift
graph.graphRadius // Double
```

Diameter:
```swift
graph.graphDiameter // Double
```

Centers:
```swift
graph.centers // [Int]
```

Availability matrix:
```swift
graph.getAvailabilityMatrix() // [[Int]]
```

Lengthы matrix:
```swift
graph.getLengthsMatrix() // [[Int]]
```

#### Graph sorting:

DFS:
```swift
graph.getDFSvertexes(fromVertex: 2) // [SWGVertex]
```

BFS:
```swift
graph.getBFSvertexes(fromVertex: 2) // [SWGVertex]
```

### Edges
Edges are initialized in graph internaly and must not be initialized manually.

#### Operations with edges

Getting edges from graph:
```swift
let edges = graph.edges // [SWGEdge]
```
Like a graph types, edges age get-only and can be modified only with functions listed below:

Adding edges to graph:
```swift
graph.addEdge(start: 2, end: 3, value: nil) // Adds edge from vertex 2 to 3
graph.addEdge(start: 16, end: 7, value: 13) // Adds edge from vertex 16 to 7 with value of 13
```

Removing edges from graph:
```swift
graph.removeEdge(at: 3) // Removes edge with number 3
graph.removeLastEdge() // Removes last edge
```

#### Getting edge's vertices and connections

Getting start and end vertices numbers:
```swift
let startIndex = edge.startVertexNumber // Int
let endIndex = edge.endVertexNumber // Int
```

Getting start and end connections:
```swift
let startConnections = edge.startVertexConnections // [SWGEdge]
let endConnections = edge.endVertexConnections // [SWGEdge]
```

### Vertices

#### Getting vertices
Getting vertices from graph:
```swift
let vertices = graph.vertexes // [SWGVertex]
```

Vertex is represented by `SWGVertex`:
```swift
public struct SWGVertex: CustomStringConvertible {

    public var description: String {
        return "SWGVertex(Number: \(self.number), Connections: [ \(self.connectedVertexes) ])"
    }

    public var number: Int
    public var connectedVertexes: [SWGVertexConnection]
}
```

Vertexe's `connectedVertexes` are represented by array of `SWGVertexConnection`:
```swift
public struct SWGVertexConnection: CustomStringConvertible {

    public var description: String {
        return "(\(self.direction) connection to \(self.connectedToVertex) with value \(self.connectionValue))"
    }

    public var direction: SWGVertexConnectionDirection
    public var connectedToVertex: Int
    public var connectionValue: Int?
}
```

Connection's direction is of type `SWGVertexConnectionDirection`:
```swift
public enum SWGVertexConnectionDirection {
    case In
    case Out
}
```

#### Vertices info and methods

Vertices types:
```swift
vertex.isLeaf // Bool
vertex.isSink // Bool
vertex.isSource // Bool
vertex.isIsolated // Bool
```

Getting distance between two vertices:
```swift
graph.lengthInGraph(from: 3, to: 4) // Double
```

Getting vertex eccentricity:
```swift
graph.getEccentricity(forVertex: 3) // Double
```

## Author

VihlayewAlex<EMAIL_ADDRESS>
## License

SWGraphs is available under the MIT license. See the LICENSE file for more info.

repository: VihlayewAlex/SWGraphs

repo_name: VihlayewAlex/SWGraphs


text:
---
title: increase() function
description: >
  The `increase()` function calculates the cumulative sum of **non-negative** differences
  between subsequent values.
aliases:
  - /influxdb/v2.0/reference/flux/functions/transformations/aggregates/increase
  - /influxdb/v2.0/reference/flux/functions/built-in/transformations/aggregates/increase/
  - /influxdb/v2.0/reference/flux/stdlib/built-in/transformations/aggregates/increase/
  - /influxdb/v2.0/reference/flux/stdlib/built-in/transformations/increase/
  - /influxdb/cloud/reference/flux/stdlib/built-in/transformations/increase/
menu:
  flux_0_x_ref:
    name: increase
    parent: universe
weight: 102
flux/v0.x/tags: [transformations]
related:
  - /{{< latest "influxdb" >}}/query-data/flux/increase/
introduced: 0.71.0
---

The `increase()` function calculates the cumulative sum of **non-negative** differences
between subsequent values.
A main use case is tracking changes in counter values which may wrap over time
when they hit a threshold or are reset.
In the case of a wrap/reset, we can assume that the absolute delta between two
points will be at least their non-negative difference.

_**Output data type:** Float_

```js
increase(columns: ["_value"])
```

## Parameters

### columns {data-type="array of strings"}
Columns to use in the operation.
Default is `["_value"]`.

### tables {data-type="stream of tables"}
Input data.
Default is piped-forward data ([`<-`](/flux/v0.x/spec/expressions/#pipe-expressions)).

## Output tables
For each input table with `n` rows, `derivative()` outputs a table with `n - 1` rows.

## Examples

{{% flux/sample-example-intro %}}

```js
import "sampledata"

sampledata.int()
  |> increase()
```

{{< expand-wrapper >}}
{{% expand "View input and output" %}}
{{< flex >}}
{{% flex-content %}}

##### Input data
{{% flux/sample "int" %}}

{{% /flex-content %}}
{{% flex-content %}}

##### Output data

| _time                | tag | _value |
| :------------------- | :-- | -----: |
| 2021-01-01T00:00:10Z | t1  |     12 |
| 2021-01-01T00:00:20Z | t1  |     12 |
| 2021-01-01T00:00:30Z | t1  |     22 |
| 2021-01-01T00:00:40Z | t1  |     22 |
| 2021-01-01T00:00:50Z | t1  |     22 |

| _time                | tag | _value |
| :------------------- | :-- | -----: |
| 2021-01-01T00:00:10Z | t2  |      0 |
| 2021-01-01T00:00:20Z | t2  |      0 |
| 2021-01-01T00:00:30Z | t2  |     22 |
| 2021-01-01T00:00:40Z | t2  |     22 |
| 2021-01-01T00:00:50Z | t2  |     22 |

{{% /flex-content %}}
{{< /flex >}}
{{% /expand %}}
{{< /expand-wrapper >}}

## Function definition
```js
increase = (tables=<-, column="_value") =>
  tables
    |> difference(nonNegative: true, column:column)
    |> cumulativeSum()
```


text:
+++
# Recent Posts widget.
# This widget displays recent posts from `content/projects/`.
widget = "projects"
active = true
date = "2016-04-20T00:00:00"

title = "Projects"
subtitle = ""

# Order that this section will appear in.
weight = 40

# Filter posts by tag.
#  By default, show all recent posts.
#  Filtering example: `tags_include = ["hugo", "academic"]`
tags_include = []
tags_exclude = []

# Number of posts to list.
count = 4

+++

C. Bugg, Zezhi Zhang,  [Integer Programming Approaches to the Quadratic Knapsack Problem](https://drive.google.com/file/d/1iVIAVDxlIGZ5DPmxNyTPC_od9EaOiH8n/view?usp=sharing), Spr 2020, UC Berkeley\
\
C. Bugg, Pelagie Elimbi Moudio, [Uses and Extensions of the Ramsey-Cass-Koopmans Model](https://drive.google.com/file/d/1Ogjroq81mA-kfEr9cBqIaZX_V7qiw1tL/view?usp=sharing), Spring 2018, UC Berkeley.
\
C. Bugg, [An Engineering Ethics Portfolio](https://drive.google.com/file/d/18S9HbjZSqOhk2mV74-2Xo3oHuoMvALj9/view?usp=sharing), Spring 2019, UC Berkeley\
\
C. Bugg, [Binomial Solutions to Smale's 17th](https://www.math.tamu.edu/ugs/research/REU/results/REU_2014/CalebBuggPaper.pdf), Summer 2014, Texas A&M University.

repository: caleb-bugg/website

repo_name: caleb-bugg/website


text:
Cache Cleaner [![Build Status](https://travis-ci.org/Frozen-Developers/android-cache-cleaner.svg)](https://travis-ci.org/Frozen-Developers/android-cache-cleaner)
======================

Cache Cleaner for Android:

  - KISS philosophy
  - **No ads**
  - Fast and clean
  - Does not require root

That says it all.

Deprecation
-----------
You do not need this app anymore if you are on Android 6.0 or newer. Just go to `Settings` ->
`Storage & USB`-> `Internal storage` and click on `Cached data` in order to clear all the cache.

Partial incompatibility with Android 6.0 and newer
------------------------------------------
Starting with Android 6.0, ```CLEAR_APP_CACHE``` permission seems to be no longer available to
regular applications and since this permission is required for cleaning of internal cache, Cache
Cleaner is not able to clean internal cache on Android 6.0 and newer. However, cleaning of external
cache is still supported.

Download
--------

[<img src="https://play.google.com/intl/en_us/badges/images/apps/en-play-badge.png" alt="Google Play Store" height="60px">](https://play.google.com/store/apps/details?id=com.frozendevs.cache.cleaner)
[![F-Droid](https://guardianproject.info/wp-content/uploads/2014/07/logo-fdroid.png)](https://f-droid.org/repository/browse/?fdid=com.frozendevs.cache.cleaner)


text:
# Auto updating facebook webhook for dev with ngrok

* This script allows to create/update a webhook subscription to a facebook app for dev with a secure ssh tunnel listening on port 8080
    * https://developers.facebook.com/docs/graph-api/reference/v3.2/app/subscriptions
    * https://ngrok.com

* Make sure that ngrok is installed on the same directory
* Modify scripted file permissions with chmod (Linux user) (chmod 755 update.sh)
* Update .env file with facebook properties
    * **FB_APP_ID** : The Messenger application id.
    * **FB_APP_ACCESS_TOKEN** : The acces token facebook app. (Check https://developers.facebook.com/tools/access_token/
    * **FB_APP_FIELDS** : The set of fields that are subsciped to ( For example : "messages,messaging_postbacks,messaging_optins,messaging_account_linking")
    * **FB_APP_VERIFY_TOKEN** : A token (choose what you want) used when registering the webhook in the Messenger admin interface.
* Usage: ./update.sh

repository: smramdani/tock

repo_name: smramdani/tock


text:
# Disallow `Array#reduce()` and `Array#reduceRight()`

`Array#reduce()` and `Array#reduceRight()` usually [result in hard-to-read code](https://twitter.com/jaffathecake/status/1213077702300852224). In almost every case, it can be replaced by `.map`, `.filter`, or a `for-of` loop. It's only somewhat useful in the rare case of summing up numbers.

Use `eslint-disable` comment if you really need to use it.

This rule is not fixable.

## Fail

```js
array.reduce(reducer, initialValue);
```

```js
array.reduceRight(reducer, initialValue);
```

```js
array.reduce(reducer);
```

```js
[].reduce.call(array, reducer);
```

```js
[].reduce.apply(array, [reducer, initialValue]);
```

```js
Array.prototype.reduce.call(array, reducer);
```

## Pass

```js
// eslint-disable-next-line unicorn/no-array-reduce
array.reduce(reducer, initialValue);
```

```js
let result = initialValue;

for (const element of array) {
	result += element;
}
```

repository: bmish/eslint-plugin-unicorn

repo_name: bmish/eslint-plugin-unicorn


text:
# Senegal Mobile Data

This repo contains data sets for the second Data for Development (D4D) Challenge. The data were wangled from Orange's
mobile phone users in Senegal, wich consist of three subsets:

* Dataset 1: One year of site-to-site traffic for 1666 sites on an hourly basis,

* Dataset 2: Fine-grained mobility data (site level) on a rolling 2-week basis with bandicoot behavioral indicators at
  individual level for about 300,000 randomly sampled users meeting the two criteria mentioned before for each 2 week
  period,

* Dataset 3: One year of coarse-grained (123 arrondissement level) mobility data with bandicoot behavioral indicators at
  individual level for about 150,000 randomly sampled users meeting the two criteria mentioned before for a year

## Data path

    hdfs://user/omnilab/warehouse/Senegal

## Data format

For more introduction of data collection, preprocessing and format, refer to [this
paper](http://arxiv.org/abs/1407.4885).

## Data sample

    1,2013-01-07 13:10:00,461
    1,2013-01-07 17:20:00,454
    1,2013-01-07 17:30:00,454
    1,2013-01-07 18:40:00,327
    1,2013-01-07 20:30:00,323
    1,2013-01-08 18:40:00,323
    1,2013-01-08 19:30:00,323
    1,2013-01-08 21:00:00,323
    1,2013-01-09 11:00:00,323
    1,2013-01-09 14:50:00,323

repository: OMNILab/OmniDataHouse

repo_name: OMNILab/OmniDataHouse


text:
# Initial functions :: Overview

3 initial primitive recursive functions:
- 1. *successor*
  - names:      `σ`, `S`, `succ`
  - arity:       1 (unary)
  - signature:   succ :: ℕ -> ℕ
  - definition:  succ n = n + 1    where n ∈ ℕ
  - notes:
    - succ is one single function (not a family of functions)
    - succ cannot fail
- 2. *constant*
  - names:       `C`, `c`, `const`
  - form:        `Cᵏₙ` where `n ∈ ℕ` and `k ∈ ℕ`
  - arity:       from 0 to k args
  - signature:   C :: ℕᵏ -> ℕ
  - definition:  Cᵏₙ(x₀, x₁,...,xₖ) = n
  - notes:
    - const can be defined from `zero` and `succ` by successive composition
      - 0 = Cᵏ₀ x̅ = Z
      - 1 = Cᵏ₁ x̅ = S ∘ Z
      - 2 = Cᵏ₂ x̅ = S ∘ S ∘ Z
      - etc.
      - use this to define fn with literals, e.g `f x = 2x` as `mul(C₂,id)`
    - const ignores all its args and returns a pre-fixed number `n`
    - const is a family of functions
      - family of functions for each arity `k`, `C⁰ₙ, C¹ₙ, C²ₙ, …`
        - C⁰ₙ       = n
        - C¹ₙ a     = n
        - C²ₙ a b   = n
        - C³ₙ a b c = n
      - family of functions for each returned number `n`, `Cᵏ₀, Cᵏ₁, Cᵏ₂, …`
        - Cᵏ₀ x̅ = 0
        - Cᵏ₁ x̅ = 1
        - Cᵏ₂ x̅ = 2
        - Cᵏ₃ x̅ = 3
  + *zero*:
    - zero function is defined in terms of const
    - zero is an abbreviation for the form `Z = Cᵏ₀`
    - names:      `Zero`, `ζ`, `Z`
    - arity:      from 0 to k args
    - signature:  Z :: ℕᵏ -> ℕ
    - definition: Zᵏ(x₀, x₁,...,xₖ) = 0
- 3. *projection*
  - names:       `P`, `π`, `proj`, `Proj`
  - form:        `πᵏᵢ` where `k > 0` and `1 <= i <= k`
  - arity:       from 1 to k args
  - signature:   proj :: ℕᵏ -> ℕ
  - definition:  projᵏᵢ(x₀, x₁,...,xₖ) = xᵢ
  - notes:
    - proj is a family of functions depending on arity `k` and index `i`,
      but the index further depends on the arity, `1 <= i <= k`
    - This means that for each fixed arity number `m`, there are `m` functions:
      the first one returns the first arg (out of `m` args), the second one returns the second arg, and so on. More concretely:
    - for k=1 there is only one function since 1 <= i <= 1
      - `π¹₁ a = a`
        this one is abbreviated as the *identity* fucntion, `π¹₁ = id`
    - for k=2 there are 2 more functions since 1 <= i <= 2
      - (previous functions for k=1)
      - `π²₁ a b = a`
        this one is abbreviated as the *fst* fucntion, `π²₁ = fst`
      - `π²₂ a b = b`
        this one is abbreviated as the *snd* fucntion, `π²₂ = snd`
    - for k=3 there are 3 more functions since 1 <= i <= 3
      - (previous functions for k=1, k=2)
      - π³₁ a b c = a
      - π³₂ a b c = b
      - π³₃ a b c = c
    - for k=m (where m is a fixed number) there are `m` since 1 <= i <= m
      - (previous functions for k=1, k=2, …, k=m-1)
      - πᵐ₀(x₀, x₁,...,xₘ) = x₀
      - πᵐ₁(x₀, x₁,...,xₘ) = x₁
      - πᵐ₂(x₀, x₁,...,xₘ) = x₂
      - …
      - πᵐₘ(x₀, x₁,...,xₘ) = xₘ
    - Total number of functions
      ```
      k | total
      1 | 1
      2 | 2 + 1
      3 | 3 + 2 + 1
      m | m + m-1 + … + 3 + 2 + 1 = Δ m
        where
        Δ m = m(m + 1) / 2
      ```
  - abbrevations
    - *id* is abbrevation for `id = proj¹₁`
    - *fst* is abbrevation for `fst = proj²₁`
    - *snd* is abbrevation for `snd = proj²₂`