text:
# 0.9.11 Release

- guid: 1390D163-9CEC-493D-839D-3930B9FFB6C4
- author: Mihael Pranjić
- pubDate: Wed, 05 Oct 2022 08:14:35 +0200
- shortDesc: New Backend System, Opensesame Application, FLOSS Course

We are proud to release Elektra 0.9.11.

## What is Elektra?

Elektra serves as a universal and secure framework to access configuration settings in a global, hierarchical key database.
For more information, visit [https://libelektra.org](https://libelektra.org).

You can also read the news [on our website](https://www.libelektra.org/news/0.9.11-release).

You can try out the latest Elektra release using our Docker image [elektra/elektra](https://hub.docker.com/r/elektra/elektra).
This is the quickest way to get started with Elektra without compiling and other obstacles, simply run:

```sh
docker pull elektra/elektra
docker run -it elektra/elektra
```

## Highlights

- Preparing new-backend merge
- Olimex
- Improving Elektra in FLOSS course

### Preparing new-backend merge

In a separated branch we rewrote the whole backend system.
With this new backend system, backends are now also plugins, allowing backends also to be non-file-based, e.g., using databases.
The main purpose of this release is to give a last stable release before master gets disrupted with a huge changeset.
The next release is not to be expected in this year.

A huge thanks to _(Klemens Böswirth @kodebach)_, _(Maximilian Irlinger @atmaxinger)_ for the many changes in the branch.
Thanks to _(Richard Stöckl @Eiskasten)_ for testing.

### Olimex

Elektra is used for [server, desktop and embedded](/doc/WHO.md).
With this release, we strengthen our embedded mainstay, specifically in [open source hardware OSHW](https://freedomdefined.org/OSHW).
We developed a major application running on OSHW [Olimex](https://www.olimex.com/Products/OLinuXino/open-source-hardware) boards.
The application is called [opensesame](https://opensesame.libelektra.org).
It is heavily relying on Elektra and [ansible-libelektra](https://github.com/ElektraInitiative/ansible-libelektra).

In the initial release [opensesame](https://opensesame.libelektra.org) already allows:

- [x] opening (garage) doors via a novel PIN entry method: you can press and release buttons in any sequence
- [x] switching on entry lights
- [x] ringing doorbells
- [x] detection of fire
- [x] report events to Nextcloud chats (English and German)

To give a smoother experience when running such an application we will develop Ansible scripts to customize the Olimex base images.
They will allow changing the language, time zone, static network configuration etc.

Olimex likes this idea and will send us an A20 board.
A big thanks to [Olimex](https://www.olimex.com).

### Improving Elektra in FLOSS course

Also in the [upcoming term](https://tiss.tuwien.ac.at/course/courseDetails.xhtml?courseNr=194114&semester=2022W) Elektra will be object of study how FLOSS initiatives work.
Students will make improvements in Elektra as part of their homework, teamwork and, if chosen, also for their project.
Alternatively, they can also improve other self-chosen FLOSS initiatives.

## Plugins

The following text list news about the [plugins](https://www.libelektra.org/plugins/readme) we updated in this release.

- fix unused-but-set-variable warnings. _(Markus Raab)_

### csvstorage

- Remove superfluous if-conditions that lead to a build error on Debian Unstable _(Maximilian Irlinger @atmaxinger)_

### specload

- fail if either the spec or parentKey parameter of elektraSpecloadSendSpec is NULL _(@hannes99)_

## Libraries

The text below summarizes updates to the [C (and C++)-based libraries](https://www.libelektra.org/libraries/readme) of Elektra.

- fix unused-but-set-variable warnings. _(Markus Raab)_

### opts

- opts: fix possible 'free(): invalid pointer' error and add test for it _(@hannes99)_

## Bindings

Bindings allow you to utilize Elektra using [various programming languages](https://www.libelektra.org/bindings/readme).
This section keeps you up-to-date with the multi-language support provided by Elektra.

### Python

- add merging based on elektraMerge _(Maximilian Irlinger @atmaxinger)_

### Rust

- start again to publish on crates.io, used by opensesame _(Markus Raab)_

## Documentation

- Added [Documentation Guidelines](https://master.libelektra.org/doc/contrib/documentation.md) _(Markus Raab)_
- Decisions for changes to `keyIsBelow` and new `keyGetNextPart` functions _(@kodebach)_
- Apply fix spelling to more files. _(Markus Raab)_

### Tutorials

- opts: use arg/help instead of arg/name _(@hannes99)_

### Man Pages

- Update [FAQ](/doc/help/elektra-faq.md). _(Markus Raab)_

## Tests

- Use GoogleTest framework v1.12.1. _(Mihael Pranjić @mpranj)_

## Build

### CMake

- Fix build with newer libgit2 versions _(Fabian Vogt)_
- We now require at least CMake `3.12` (released in July 2018). _(Maximilian Irlinger @atmaxinger)_

### Docker

- Bump Alpine Linux to 3.16.0. _(Mihael Pranjić @mpranj)_
- The Docker image for building the documentation is now [based on Debian Bullseye](../../scripts/docker/debian/bullseye/doc.Dockerfile). _(Maximilian Irlinger @atmaxinger)_
- Add Fedora 36 images. _(Mihael Pranjić @mpranj)_

## Infrastructure

### Jenkins

- We no longer build and test on Ubuntu Xenial and Debian Stretch due to outdated CMake versions _(Maximilian Irlinger @atmaxinger)_
- Add Fedora 36 builds, remove Fedora 34 builds. _(Mihael Pranjić @mpranj)_

### Cirrus

- Update FreeBSD images to 13.1 and 12.3 and update packages before builds. _(Mihael Pranjić @mpranj)_
- Bump Fedora builds to Fedora 36. _(Mihael Pranjić @mpranj)_

## Website

The website is generated from the repository, so all information about
plugins, bindings and tools are always up-to-date.

## Outlook

We are currently working on following topics:

- 1.0 API _(Klemens Böswirth @kodebach)_ and _(Stefan Hanreich)_
- Elektrify KDE and GNOME _(Mihael Pranjić @mpranj)_
- Elektrify XFCE _(Richard Stöckl @Eiskasten)_
- Mounting SQL databases _(Florian Lindner @flo91)_
- Recording Configuration _(Maximilian Irlinger)_
- Ansible-Elektra _(Lukas Hartl)_ and _(Maximilian Irlinger)_
- Configure Olimex Base Images _(Maximilian Irlinger)_
- Improving Build Server Infrastructure _(Lukas Hartl)_ and _(Maximilian Irlinger)_
- Improve Java Development Experience _(Michael Tucek)_
- Rewriting tools in C _(@hannes99)_

## Statistics

We closed [17 issues](https://github.com/ElektraInitiative/libelektra/milestone/32?closed=1) for this release.

About 11 authors changed 156 files with 4020 insertions(+) and 3298 deletions(-) in 134 commits.

Thanks to all authors for making this release possible!

## Join the Initiative!

We welcome new contributors!
Read [here](https://www.libelektra.org/devgettingstarted/ideas) about how to get started.

As first step, you could give us feedback about these release notes.
Contact us via our [issue tracker](https://issues.libelektra.org).

## Get the Release!

You can download the release from

- [here](https://www.libelektra.org/ftp/elektra/releases/elektra-0.9.11.tar.gz) or from
- [GitHub](https://github.com/ElektraInitiative/ftp/blob/master/releases/elektra-0.9.11.tar.gz?raw=true)

The [hashsums are:](https://github.com/ElektraInitiative/ftp/blob/master/releases/elektra-0.9.11.tar.gz.hashsum?raw=true)

- name: elektra-0.9.11.tar.gz
- size: 9149900
- md5sum: 227094a7760f8faece1a7b8386d01fce
- sha1: a0d2f0d39c8360f67da96585993223b7f9cdebe6
- sha256: 3509adf83efdf08fa0dc5d51396772addff7d8fc82299c18b146fa4406eecff5

The release tarball is also available signed using GnuPG from

- [here](https://www.libelektra.org/ftp/elektra/releases/elektra-0.9.11.tar.gz.gpg) or on
- [GitHub](https://github.com/ElektraInitiative/ftp/blob/master/releases/elektra-0.9.11.tar.gz.gpg?raw=true)

The following GPG Key was used to sign this release: 12CC44541E1B8AD9B66AFAD55262E7353324914A

Already built API documentation can be found [here](https://doc.libelektra.org/api/0.9.11/html/) or on [GitHub](https://github.com/ElektraInitiative/doc/tree/master/api/0.9.11).

## Stay tuned!

Subscribe to the [RSS feed](https://www.libelektra.org/news/feed.rss) to always get the release notifications.

If you also want to participate, or for any questions and comments please contact us via our issue tracker [on GitHub](http://issues.libelektra.org).

[Permalink to this NEWS entry](https://www.libelektra.org/news/0.9.11-release)

For more information, see [https://libelektra.org](https://libelektra.org).

Best regards,
[Elektra Initiative](https://www.libelektra.org/developers/authors)

repository: ElektraInitiative/libelektra

gha_language: C

repo_name: ElektraInitiative/libelektra


text:
DAFI - Data Assimilation for Field Inversion
============================================
Ensemble based data-assimilation for field inversion.

Developed by Dr. Heng Xiao's group at Virginia Tech: [Data-Enabled Computational Mechanics Laboratory at Virgnia Tech.](https://www.aoe.vt.edu/people/faculty/xiaoheng/personal-page.html)

Contributors:
-------------
* Carlos A. Michelén Ströfer
* Xinlei Zhang
* Kris Olshefski
* Jianxun Wang
* Rui Sun
* Jinlong Wu

PLAN Before Release:
--------------------
* Update/write docstrings all files (Kris)
* Update/clean tutorials
  * nutFOAM (Carlos)
  * rest (Kris)
* Update documentation (Kris)
* Unit testing (Kris)
* Clean rest of code (OpenFOAM, Fields,) (Carlos)
* Release files (e.g. setup.py) (Carlos)

Release Plan (Python typical) (prefered):
-----------------------------------------
* New Git repo (name=DAFI, no history, tag release version). This will be development code.
* PyPI (so that can do ``pip install dafi``). This is for stable releases.
* Documentation hosted online at readthedocs. This would be the main website for DAFI.

repository: the-ethan-hunt/DAFI

branch_name: refs/heads/master

extension: md

license_type: permissive

repo_name: the-ethan-hunt/DAFI


text:
# consilium
simple source hosting framework

This project is a try to build some kind of source hosting
framework much like gitlab. The reason why I am starting this
is because I wasted some time with trying to get gitlab running
stable on a test machine with limited RAM.

That was not successful yet and maybe never will be,
because gitlab has serious memory leaks. Even though
they have a mechanism - they call it mechanism - to
work around these issues, they are not being called
after some time, so for a possibly idle server it
means that in worst case it will run out of RAM.

That's plainly inacceptable.

However, during playing around with gitlab,
I was confronted with its working principle
which is pretty darn simple. The most functionality
can be built using standard unix tools.

The main difference would be that my project
would NOT include any ruby code or any non-standard
way of doing things. That's why it can never be as
advanced as some of these cheating projects.

license: MIT

repository: gustopn/consilium

repo_name: gustopn/consilium


text:
# jiraToTestrail
Converts Jira tickets in XML format to a Testrail format.

Before Running:
Make sure to move your ticket xml to the same directory as script
Make sure template file is untouched and in same directory
Make sure you have python3

How to run:
Download the XML file for the Jira Ticket
Launch terminal and enter the directory your files are in
Run the script by typing “python3 script.py”
It will prompt you for your ticket name - make sure you enter the ticket name without extension and hit enter

Result:
yourticketTestrail.xml will be created in same directory
This can then be uploaded into testRail.

repository: ArgusLi/jiraToTestrail

repo_name: ArgusLi/jiraToTestrail


text:
# Gitlab Deployer for Laravel

![Hexide digital Gitlab Deployer for Laravel](https://preview.dragon-code.pro/Hexide-digital/Gitlab-Deployer-for-Laravel.svg?background=0b0b69&mode=dark)

This package was created to optimize and improve a company's CI/CD in a Gitlab environment.

# Requirements

This package requires **PHP 8.1** and **Laravel 9.0** or higher.

Available SSH agents on local machine and remote server.

Remote server must use GNU/Linux.

# Installation

## Add dependency

You can install this package via composer using:

```shell
composer require --dev hexide-digital/gitlab-deploy
```

And if you are using composer version 2.4 and above, run the [`bump`](https://php.watch/articles/composer-bump) command

or manually add line to `composer.json`

```json
{
    "require-dev": {
        "hexide-digital/gitlab-deploy": "^1.0"
    }
}
```

then run:

```shell
composer install
```

## Publish files and examples

The package will automatically register its service provider.

Examples of files to be copied can be viewed in
[this folder](https://github.com/hexidedigital/laravel-gitlab-deploy/tree/master/examples).

After installing, you maybe want to publish files for deployment and sample files, right? Just do this:

```shell
php artisan gitlab-deploy:install
```

# Usage

## Prepare

Open _(after publishing)_ or create the file
[`deploy/deploy-prepare.yml`](https://github.com/hexidedigital/laravel-gitlab-deploy/blob/master/examples/deploy-prepare.example.yml)
and fill all needed options.

For most cases only need to be specified next options:

- **access token** for project repository ([see tip](#gitlab-api-access-token))
- project **full name** or project **id** ([see tip](#project-full-name-or-id))
- access for the **server**
- access for the **database**

But for every stage are available next options:

- repository url
- executor paths for `php` and `composer`
- access for the server
- access for the database
- access for the mail host (but can be missed)

## Running configuration command

### Basic launch

You can begin configuring your project deployment for specific stage (i.e. for `dev` branch) by running:

```shell
php artisan deploy:gitlab dev
```

Important - see what todo [After command executing](#after-command-executing)

> By default, stage are same git branch.

#### Only-print option

If you want manually execute commands or just prepare to future deployment, set a `--only-print` option when calling
command. All command examples will be written to `deploy/dep-log.log` file. All that remains is to copy and execute
commands from the file.

#### Aliases

For more convenient use of the Laravel **artisan** command, you can add command line aliases to `~/.bashrc`
(or `~/.bash_aliases`). So you can append to file or print a log file with a `--aliases` option when calling command.

## After command executing

If all tasks completely executed, to enable auto-deployment go to
`Settings` -> `CI/CD` -> `Variables` and change value for `CI_ENABLED` to `1`. After that, when you edit
branch with configured deployment, Gitlab will run CI/CD Pipelines automatically

# Tips for Gitlab

## Gitlab API access token

In order for variables and other deployment options to be created, you need to grant access to the repository settings.
This package uses the **Gitlab API** method using **Access Tokens**.

To get Access Token follow this path `Settings` -> `Access Tokens`.

Fill next options like bellow:

- **Token name** - i.e. `deploy_dev` or `deploy_prod`
- **Expiration date** - recommended to set 1-2 days (this will be enough)
- **Role** - `mainterner` - for ability to change repository settings
- **Scopes** - only `api`

Then click `Create project access token` to see the token. **Make sure you save it - you won't be able to access it
again.**

## Project full name or ID

### Project full name

You can get full name in different ways, but most simple is copy from browser url.

I.e. url looks like `https://gitlab.com/namespace/project_name`, so **full name** will be `namespace/project_name`

### Project ID

Project ID are placed under this path `Settings` -> `General` -> `Naming, topics, avatar (alredy open)`.

But for using project ID you must wrap number to quotes like `"XXXXXXXXXX"` to mark value as string.

# Can I hire you guys?

Yes! Say hi: [hello<EMAIL_ADDRESS>We will be happy to work with you! Other [work we’ve done](https://hexide-digital.com)

## Follow us

Follow us on [LinkedIn](https://www.linkedin.com/company/hexide-digital)
or [Facebook](https://www.facebook.com/hexide.digital)

repository: hexidedigital/laravel-gitlab-deploy

gha_language: PHP

gha_license_id: MIT

repo_name: hexidedigital/laravel-gitlab-deploy


text:
# P/Invoke

**⚠ NOTICE: [Check out CsWin32](https://github.com/dotnet/pinvoke/issues/565): A new, preferred approach for Win32 p/invokes now exists for C# developers.**

This repo is no longer maintained.

---

A collection of libraries intended to contain all P/Invoke method signatures for popular operating systems.
Think of it as https://pinvoke.net, but proven to compile and work properly, and often
with sample usage in the form of unit tests.

A unique C# project wraps each native library.
The C# project may multi-target in order to support many versions of .NET Framework, .NET Core and .NET Standard.

Win32 APIs for all Windows versions are welcome.
Special Windows Store targeted assemblies omit p/invoke signatures to banned APIs so your Store apps can depend on these libraries without getting rejected by the Store certification process.

This project is supported by the [.NET Foundation](https://dotnetfoundation.org).

## Usage

Install the NuGet package(s) for the DLLs you want to P/Invoke into.
For example, if you want to P/Invoke into Win32's BCrypt.dll, install this package:

```powershell
Install-Package PInvoke.BCrypt
```

Then import the following namespaces, as demonstrated below (if using C# 6):

```csharp
using PInvoke;
using static PInvoke.BCrypt; // Supported in C# 6 (VS2015) and later.
```

This will allow you to conveniently call these methods directly by method name:

```csharp
var error = BCryptOpenAlgorithm(AlgorithmIdentifiers.BCRYPT_SHA256_ALGORITHM); // C# 6 syntax
var error = BCrypt.BCryptOpenAlgorithm(BCrypt.AlgorithmIdentifiers.BCRYPT_SHA256_ALGORITHM); // C# 5 syntax
```

Sometimes a PInvoke method may have multiple overloads. For example every method that accepts
`struct*` parameters has an overload that accepts `IntPtr` in its place. In other cases there
may be overloads that accept `struct*` and `struct?`. In some of these cases that can lead to
compiler errors if you pass in `null` because both `struct*` and `struct?` overloads can match.
To resolve the issue, add a cast to your null: `(struct?)null` to resolve the ambiguity.

### What if I need custom `uint` value not provided in `enum`?

Cast any `uint` to specific `enum` type and pass as parameter.

## Design goals

Provide a slightly higher than lowest level API for P/Invoke signatures.
For example, instead of `IntPtr` parameters and `uint` flags, you'll see `SafeHandle`-derived
types as parameters and flags `enum` types. API documentation will be provided via XML doc comments
for easy reading with Intellisense, along with links to the describing pages on MSDN
or elsewhere as applicable.

In some cases we offer several overloads of a given native method to offer native pointer and
`IntPtr` access. We encourage folks to try writing C# `unsafe` code before using `IntPtr` because
it (ironically) can often be easier to write correct and efficient code using native pointers than
all the casting and `Marshal` call overhead that `IntPtr` requires.
Note that when a method's only use of a native pointer is its return type, the `IntPtr` returning
variant must be given a different method name by CLR overloading rules, so look for the same method
but with an `_IntPtr` suffix.

## Distribution

This library should be available on NuGet for easy consumption by your projects.
You may also copy and paste the P/Invoke signatures you need directly into your projects if desired.

Packages:

Library      | Package name     | NuGet       | Description
-------------|------------------|-------------|-------------
advapi32.dll |`PInvoke.AdvApi32`| [![NuGet](https://buildstats.info/nuget/PInvoke.AdvApi32)](https://www.nuget.org/packages/PInvoke.AdvApi32)|Windows Advanced Services
bcrypt.dll   |`PInvoke.BCrypt`  | [![NuGet](https://buildstats.info/nuget/PInvoke.BCrypt)](https://www.nuget.org/packages/PInvoke.BCrypt)|[Windows Cryptography API: Next Generation][CNG]
cabinet.dll  |`PInvoke.Cabinet` | [![NuGet](https://buildstats.info/nuget/PInvoke.Cabinet)](https://www.nuget.org/packages/PInvoke.Cabinet)|[Cabinet API Functions][Cabinet]
cfgmgr32.dll |`PInvoke.CfgMgr32`| [![NuGet](https://buildstats.info/nuget/PInvoke.CfgMgr32)](https://www.nuget.org/packages/PInvoke.CfgMgr32)|[Device and Driver Installation][CfgMgr32]
crypt32.dll  |`PInvoke.Crypt32` | [![NuGet](https://buildstats.info/nuget/PInvoke.Crypt32)](https://www.nuget.org/packages/PInvoke.Crypt32)|[Windows Cryptography API][Crypt32]
DwmApi.dll   |`PInvoke.DwmApi`  | [![NuGet](https://buildstats.info/nuget/PInvoke.DwmApi)](https://www.nuget.org/packages/PInvoke.DwmApi)|[Desktop Window Manager][DwmApi]
fusion.dll   |`PInvoke.Fusion`  | [![NuGet](https://buildstats.info/nuget/PInvoke.Fusion)](https://www.nuget.org/packages/PInvoke.Fusion)|.NET Framework Fusion
gdi32.dll    |`PInvoke.Gdi32`   | [![NuGet](https://buildstats.info/nuget/PInvoke.Gdi32)](https://www.nuget.org/packages/PInvoke.Gdi32)|[Windows Graphics Device Interface][Gdi]
hid.dll      |`PInvoke.Hid`     | [![NuGet](https://buildstats.info/nuget/PInvoke.Hid)](https://www.nuget.org/packages/PInvoke.Hid)|[Windows Human Interface Devices][Hid]
iphlpapi.dll |`PInvoke.IPHlpApi`| [![NuGet](https://buildstats.info/nuget/PInvoke.IPHlpApi)](https://www.nuget.org/packages/PInvoke.IPHlpApi)|[IP Helper](IPHlpApi)
kernel32.dll |`PInvoke.Kernel32`| [![NuGet](https://buildstats.info/nuget/PInvoke.Kernel32)](https://www.nuget.org/packages/PInvoke.Kernel32)|Windows Kernel API
magnification.dll |`PInvoke.Magnification`| [![NuGet](https://buildstats.info/nuget/PInvoke.Magnification)](https://www.nuget.org/packages/PInvoke.Magnification)|[Windows Magnification API][Magnification]
mscoree.dll  |`PInvoke.MSCorEE` | [![NuGet](https://buildstats.info/nuget/PInvoke.MSCorEE)](https://www.nuget.org/packages/PInvoke.MSCorEE)|.NET Framework CLR host
msi.dll      |`PInvoke.Msi`     | [![NuGet](https://buildstats.info/nuget/PInvoke.Msi)](https://www.nuget.org/packages/PInvoke.Msi)|[Microsoft Installer][Msi]
ncrypt.dll   |`PInvoke.NCrypt`  | [![NuGet](https://buildstats.info/nuget/PInvoke.NCrypt)](https://www.nuget.org/packages/PInvoke.NCrypt)|[Windows Cryptography API: Next Generation][CNG]
netapi32.dll |`PInvoke.NetApi32`| [![NuGet](https://buildstats.info/nuget/PInvoke.NetApi32)](https://www.nuget.org/packages/PInvoke.NetApi32)|[Network Management][NetApi32]
newdev.dll   |`PInvoke.NewDev`  | [![NuGet](https://buildstats.info/nuget/PInvoke.NewDev)](https://www.nuget.org/packages/PInvoke.NewDev)|[Device and Driver Installation][NewDev]
ntdll.dll    |`PInvoke.NTDll`   | [![NuGet](https://buildstats.info/nuget/PInvoke.NTDll)](https://www.nuget.org/packages/PInvoke.NTDll)|Windows NTDll
psapi.dll    |`PInvoke.Psapi`   | [![NuGet](https://buildstats.info/nuget/PInvoke.Psapi)](https://www.nuget.org/packages/PInvoke.Psapi)|[Windows Process Status API][Psapi]
setupapi.dll |`PInvoke.SetupApi`| [![NuGet](https://buildstats.info/nuget/PInvoke.SetupApi)](https://www.nuget.org/packages/PInvoke.SetupApi)|[Windows setup API][SetupApi]
SHCore.dll   |`PInvoke.SHCore`  | [![NuGet](https://buildstats.info/nuget/PInvoke.SHCore)](https://www.nuget.org/packages/PInvoke.SHCore)|[Windows Shell][Shell32]
shell32.dll  |`PInvoke.Shell32` | [![NuGet](https://buildstats.info/nuget/PInvoke.Shell32)](https://www.nuget.org/packages/PInvoke.Shell32)|[Windows Shell][Shell32]
user32.dll   |`PInvoke.User32`  | [![NuGet](https://buildstats.info/nuget/PInvoke.User32)](https://www.nuget.org/packages/PInvoke.User32)|[Windows User Interface][User32]
userenv.dll  |`PInvoke.Userenv` | [![NuGet](https://buildstats.info/nuget/PInvoke.Userenv)](https://www.nuget.org/packages/PInvoke.Userenv)|Windows User Environment
uxtheme.dll  |`PInvoke.UxTheme` | [![NuGet](https://buildstats.info/nuget/PInvoke.UxTheme)](https://www.nuget.org/packages/PInvoke.UxTheme)|[Windows Visual Styles][UxTheme]
winusb.dll   |`PInvoke.WinUsb`  | [![NuGet](https://buildstats.info/nuget/PInvoke.WinUsb)](https://www.nuget.org/packages/PInvoke.WinUsb)|[USB Driver][WinUsb]
WtsApi32.dll |`PInvoke.WtsApi32`| [![NuGet](https://buildstats.info/nuget/PInvoke.WtsApi32)](https://www.nuget.org/packages/PInvoke.WtsApi32)|[Windows Remote Desktop Services][WtsApi32]

Check out the [P/Invoke coverage][PInvokeCoverageReport] we have for each library.

If you need a P/Invoke that is in our source code but not yet released to nuget.org, you can consume the packages directly from our CI feed by adding this package source to your nuget.config file

```xml
<add key="PInvoke" value="https://pkgs.dev.azure.com/andrewarnott/OSS/_packaging/PublicCI/nuget/v3/index.json" />
```

## Contribution

Please consider [contributing](CONTRIBUTING.md) more P/Invoke method signatures to this project.
Once you contribute, you can immediately consume your additions without waiting for another
public release of the library.

This project has adopted the code of conduct defined by the Contributor Covenant to clarify expected behavior in our community.
For more information see the [.NET Foundation Code of Conduct](https://dotnetfoundation.org/code-of-conduct).

[CfgMgr32]: https://docs.microsoft.com/en-us/windows/win32/api/cfgmgr32/
[CNG]: https://msdn.microsoft.com/en-us/library/windows/desktop/aa376210
[Crypt32]: https://msdn.microsoft.com/en-us/library/windows/desktop/aa380256
[DwmApi]: https://msdn.microsoft.com/en-us/library/windows/desktop/aa969540.aspx
[Hid]: https://msdn.microsoft.com/en-us/library/windows/hardware/ff538865
[IPHlpApi]: https://docs.microsoft.com/en-us/windows/win32/api/_iphlp/
[Magnification]: https://msdn.microsoft.com/en-us/library/windows/desktop/ms692162
[Msi]: https://msdn.microsoft.com/en-us/library/aa372860.aspx
[SetupApi]: https://msdn.microsoft.com/en-us/library/windows/hardware/ff550855
[Gdi]: https://msdn.microsoft.com/en-us/library/dd145203
[Psapi]: https://msdn.microsoft.com/en-us/library/windows/desktop/ms684884.aspx
[UxTheme]: https://msdn.microsoft.com/en-us/library/windows/desktop/bb773187.aspx
[NetApi32]: https://msdn.microsoft.com/en-us/library/windows/desktop/aa370680.aspx
[NewDev]: https://docs.microsoft.com/en-us/windows/win32/api/newdev/
[Shell32]: https://msdn.microsoft.com/en-us/library/windows/desktop/bb773177.aspx
[WinUsb]: https://docs.microsoft.com/en-us/windows/win32/api/winusb/
[WtsApi32]: https://msdn.microsoft.com/en-us/library/aa383468(v=vs.85).aspx
[Cabinet]: https://docs.microsoft.com/en-us/windows/win32/devnotes/cabinet-api-functions
[User32]: https://docs.microsoft.com/en-us/windows/win32/api/winuser

[PInvokeCoverageReport]: https://github.com/dotnet/pinvoke/wiki/coverage

repository: dotnet/pinvoke

branch_name: refs/heads/main

gha_language: C#

repo_name: dotnet/pinvoke


text:
# Soknadsmottaker
When a user applies for a benefit (_sender inn en søknad_), one or more documents are sent in to NAV. This component acts as a REST-endpoint to which the systems that the user uses can send metadata about the benefit. The documents themselves are sent to a different system, [Soknadsfillager](https://www.github.com/navikt/soknadsfillager).

When Soknadsmottaker receives data, it will be converted, serialized as an Avro message and put on a Kafka topic.

Soknadsmottaker also has REST-interfaces for publishing _brukernotifikasjoner_ to Kafka topics.

For a description of the whole archiving system, see [the documentation](https://github.com/navikt/archiving-infrastructure/wiki).

## Rest-API
The Rest-API can be accessed here:

* [localhost](http://localhost:8090/swagger-ui/index.html)
* [preprod](https://soknadsmottaker-gcp.dev.intern.nav.no/swagger-ui/index.html)
* [loadtests (preprod)](https://soknadsmottaker-gcp-loadtests.dev.intern.nav.no/swagger-ui/index.html)
* [prod](https://soknadsmottaker-gcp.intern.nav.no/swagger-ui/index.html)

# Dependencies
This component requires the following to work:
* [soknadarkiv-schema](https://github.com/navikt/soknadarkiv-schema) (Avro schema definitions)
* Kafka broker (for providing Kafka topics to send to)

## Secure logs
The application will log the requests it receives, but mask the personId / fødselsnummer / fnr. For debugging and resending purposes, the fnr is needed. It can be found in the secure logs of the application, accessible via Kibana or Kubectl.

### Kibana
The secure logs can be accessed from [Kibana](https://logs.adeo.no/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:0),time:(from:now-1h,to:now))&_a=(columns:!(message,envclass,level,application,host),filters:!(),index:'tjenestekall-*',interval:auto,query:(language:lucene,query:'envclass:q%20AND%20application:soknadsmottaker'),sort:!())). Change index in Kibana from `logstash-*` to `tjenestekall-*` in the left menu, as in the screenshot below. If you lack access, it is most likely because you are not in the AD-group. See [the nais documentation](https://doc.nais.io/observability/logs/#3-put-people-into-the-ad-group) for details.

![Change Kibana index from logstash to tjenestekall in the left menu](kibana_securelogs.png "Change Kibana index from logstash to tjenestekall in the left menu")

### Kubectl
The secure logs can be accessed from the terminal using kubectl as shown below. Remember to look in all pods for the log line that you search for.
```
$ kubectl -n team-soknad get pods | grep soknadsmottaker
soknadsmottaker-86745fb779-lndkn    3/3    Running    0    2d18h
soknadsmottaker-86745fb779-r7ffk    3/3    Running    0    2d18h

$ kubectl -n team-soknad exec --stdin --tty soknadsmottaker-86745fb779-lndkn -- /bin/bash
Defaulting container name to soknadsmottaker.
Use 'kubectl describe pod/soknadsmottaker-86745fb779-lndkn -n team-soknad' to see all of the containers in this pod.

apprunner@soknadsmottaker-86745fb779-lndkn:/app$ ls -la /secure-logs/
total 14344
drwxrwxrwx. 2 root      root          4096 feb.  22 15:35 .
drwxr-xr-x. 1 root      root          4096 feb.  22 15:35 ..
-rw-r--r--. 1 apprunner apprunner 14666703 feb.  25 10:17 secure.log
-rw-r--r--. 1      1065      1065        0 feb.  22 15:35 secure-logs-mlog.pos
-rw-r--r--. 1      1065      1065       58 feb.  25 10:17 secure-logs.pos

apprunner@soknadsmottaker-86745fb779-lndkn:/app$ cat /secure-logs/secure.log
<LOG CONTENT>
```

## Resending requests
If a Soknad for some reason fails to be sent through the whole archiving chain, a last resort is to manually resend it, as explained below. Save your data into a json-file called "soknader.json" (an example can be seen [here](mottaker/src/main/resources/soknader.json)), and run the script below (requires curl and [jq](https://github.com/stedolan/jq)). To send failed files to Soknadsfillager, see [its documentation](https://github.com/navikt/soknadsfillager#manually-sending-files-to-soknadsfillager).

Run the script first against localhost:8090 (i.e. start Soknadsmottaker on your own machine) to see that it works as expected. Then do a test run against preprod (i.e. replace `soknadsmottakerurl` with https://soknadsmottaker-gcp.dev.intern.nav.no). When you have verified that the behaviour and data is as expected, you can run against production with care.

One must never send in a Soknad with the same innsendingId as a previous one. The script will replace whatever innsendingId is set to, with a newly generated UUID.

Update `credentials` with the username and password, which you can find in [GCP Secret Manager](https://console.cloud.google.com/security/secret-manager/secret/shared-innsending-secret/versions?project=team-soknad-dev-ee5e) (remember to select the correct project - dev or prod). Note that the script will save the password to your shell history (e.g. in ~/.bash_history), which is a bad side effect. Two options are available:
* After running the script, you can manually remove the password from your shell history file.
* You can set `credentials=innsending` rather than `credentials=innsending:password`. This will make curl prompt you for the password for each Soknad in soknader.json. If you have only a few Soknader to send in it should be no problem, but if you have many it might be cumbersome, and you should in that case opt for manually cleaning your shell history file instead.
```
soknadsmottakerurl=http://localhost:8090/soknad ;\
credentials=innsending:password ;\
jq -c '.[] | objects' soknader.json  | while read obj ; do
    jq -c --arg id $(uuidgen) '.innsendingId = $id' <<< "$obj" \
    | curl -X POST -H 'Content-Type: application/json' -d @- $soknadsmottakerurl -u $credentials
done
```

## Inquiries
Questions regarding the code or the project can be asked to the team by [raising an issue on the repo](https://github.com/navikt/soknadsmottaker/issues).

### For NAV employees
NAV employees can reach the team by Slack in the channel #teamsoknad

repository: navikt/soknadsmottaker

gha_language: Kotlin

repo_name: navikt/soknadsmottaker


text:
## High availability mode

#### conf.js

conf.js must contain credentials for connection to an external database shared by channels watcher and front instances.

```javascript
exports.bLight = true; // change to false to run as full node
exports.bSingleAddress = true; //should always be true

exports.WS_PROTOCOL = "wss://";
exports.hub = process.env.testnet ? 'obyte.org/bb-test' : 'obyte.org/bb';
exports.deviceName = 'AA-channel-application';
exports.permanent_pairing_secret = '0000';
exports.control_addresses = [''];

exports.minChannelTimeoutInSecond = 600;  // timeout value under which channel creation request will be refused
exports.maxChannelTimeoutInSecond = 1000; // timeout value above which channel creation request will be refused
exports.defaultTimeoutInSecond = 600;. // default timeout value for channels created by me

exports.isHighAvailabilityNode =  true;

exports.enabledReceivers = ['http']; //configure the communication layers that can receive a message from peer
// if 'http' is present, a http server will start to listen at port httpDefaultPort

exports.httpDefaultPort = 6800;

exports.app_database = {};
exports.app_database.host = '<IP_ADDRESS>';
exports.app_database.name = 'app_db';
exports.app_database.user = 'app_db_user';
exports.app_database.password = '1234';
```

# Usage:

Require the module where you need it in your project.

`const channels = require('aa-channels-lib')`

Require the channels watcher in a script that runs separately

`require('aa-channels-lib/aa_watcher.js')`

The watcher can be stopped and restarted without provoking a down time for your application.

You can run several front applications each having different http ports configured in their respective conf.js. They must connect to same database.

repository: xJeneKx/aa-channels-lib

repo_name: xJeneKx/aa-channels-lib


text:
---
versionFrom: 7.0.0
---

# Deploying from Local to Cloud

When you are working with your Umbraco Cloud project locally all changes you make will automatically be identified and picked up by your local Git client.

Here's a quick step-by-step on how you deploy these changes to your Cloud environment:

- You’ve cloned a site to your local machine to work on
- You’ve made some changes to a Document type
- The corresponding `.uda` file for this Document type is now updated with the changes - the file is located in the `/data/revision` folder
- You’ve also created a new data type that’s used on the document type. This data type is stored as a new file in the `/data/revision` folder as well
- Using Git, commit those two changed files to your local repository and push them to the Cloud environment using `git push`
- On the Cloud environment a deployment kicks in and the document type is updated and the new data type you created locally is now automatically created in the Cloud environment as well

![Deploy from Local to Remote](images/stage-commit-deploy.gif)

In the above example, GitKraken is used to stage, commit and deploy changes made to a Document type plus a newly added data type from a local environment to a Cloud Development environment. You are welcome to use any Git client or cli of your choice.

Once you’ve deployed your local changes to your Cloud environment deploying to your remaining Cloud environments (e.g. Staging and/or Live) is done using the **'Deploy changes to ..'** button in the Umbraco Cloud portal. Learn more about how this is done in our section about [deploying between two Cloud environments](../Cloud-to-Cloud).

## Deploying without using a Git client

If you don't have a Git client installed on your local machine, or prefer to work with Git through command line, you can use eg. Git Bash and the following commands:

    # Navigate to the repository folder
    cd mySite
    # Check status of the repository for pending changes
    git status
    # Add pending changes
    git add -A
    # Commit staged files
    git commit -m "Adding updated schema changed"
    # Push to the remote Development environment
    git push origin master

    # If the push is rejected you will need to pull first
    git pull origin master
    # Try to push again if there were no conflicts
    git push origin master

If you had to pull down new commits, it is a good idea to see if any of these commits contained changes to the schema (anything in `/Data/Revision/`). In order to ensure that your local site is up-to-date, and your changes work with the updated schema, you can navigate to the `/data/` folder and create a deploy marker if one doesn't already exist. From a command line type the following command:

`/…mysite/data> echo > deploy`

The local site should be running when you do this. The deploy marker will change to `deploy-progress` while updating the site and `deploy-complete` when done. If there are any conflicts/errors you will see a `deploy-failed` marker instead, which contains an error message with a description of what went wrong.

**Pro Tip:** Check the timestamp on the `deploy-complete` marker to see if it has been updated.

repository: jakob-bagterp/UmbracoDocs

repo_name: jakob-bagterp/UmbracoDocs


text:
![Icon](https://raw.github.com/jbogard/NServiceBus.MessageRouting/master/package_icon.png)

NServiceBus.MessageRouting
==========================

*Implementations of EIP message routing patterns for NServiceBus*

Currently the patterns implemented include the routing slip. Planned are a true saga implementation (w/ compensating actions) and more.

![CI](https://github.com/jbogard/NServiceBus.MessageRouting/workflows/CI/badge.svg)
[![NuGet](https://img.shields.io/nuget/dt/NServiceBus.MessageRouting.svg)](https://www.nuget.org/packages/NServiceBus.MessageRouting)
[![NuGet](https://img.shields.io/nuget/vpre/NServiceBus.MessageRouting.svg)](https://www.nuget.org/packages/NServiceBus.MessageRouting)
[![MyGet (dev)](https://img.shields.io/myget/nservicebus-messagerouting-ci/v/NServiceBus.MessageRouting.svg)](https://myget.org/gallery/nservicebus-messagerouting-ci)

Routing Slips
-------------

The [Routing Slip pattern](http://www.enterpriseintegrationpatterns.com/RoutingTable.html) enables you to route a message to one or more destinations. Each step handles the message and forwards to the next step.

Forwarding is transparent to each handler, nor does each handler need to have any additional configuration for other steps.

Kick off the process by sending a message and including the list of destinations, either from an IPipelineContext inside a message handler or IMessageSession from your endpoint instance:

```c#
// From your endpoint instance
endpoint.Route(order, new[] {"Validate", "Fraud", "CreditCheck", "Process"});

// Inside a message handler
context.Route(order, new[] {"Validate", "Fraud", "CreditCheck", "Process"});
```

Each endpoint needs to include a handler for the message. Optionally, each endpoint can inspect/modify routing slip attachments:

```c#
context.Extensions.Get<RoutingSlip>().Attachments["FraudResult"] = "Declined";
```

Routing slip attachments are data that you share between different handlers in the route steps. As the message flows from step to step, the original raw transport message is passed through as-is.

That's all there is to it!

## Icon

Route designed by Steven Lester from The Noun Project


text:
# hoshi
A simple pipeline processor inspired by Y86 written in Rust.
Some design comes from *Computer System: A Programmer's Perspective*, which is known as *CSAPP* in short.

## Unfinished
1. Memory
2. Exception handler
3. Multi-period instructions

## Usage
run `cargo run` to generate Verilog code in this path.

repository: Brethland/hoshi

repo_name: Brethland/hoshi


text:
---
layout: post
title: Bad Design
subtitle: Things That Didn't Go Well
---

**The Mission Showers**

The mission showers present an example of bad design.  At first glance they seem intutive, you turn the handle to hot or cold.  This allows water to flow from the bottom faucet, but what about when you want to take a shower?  This becomes harder.  There is a nob, that upon inspection seems to be able to pushed, pulled, or twisted.  To make matters worse, it is labeled "volume".  This language is not indicative of the common words surrounding shower usage.  It is also unclear whether or not the nob should be used at all to control shower usage, or if so, if it should be used before or after the water is running.  The design of this mechanism is flawed further because it does not take into account the state in which its users will be when they use the shower.  Commonly people take showers either first thing in the morning, when they are groggy, or before bed, when they are tired.  During both times users are not at their sharpest, and so it makes the mechanism ever harder to operate.

![img_2229](/img/IMG_2229.jpg)

The solution to the nob is to run the lower faucet, and then push in the nob to start the shower.


text:
# HyperV - SmallLab 2012R2 Single Client

INSERT TEXT HERE

```powershell
$labName = 'SmallClient'

#create an empty lab template and define where the lab XML files and the VMs will be stored
New-LabDefinition -Name $labName -DefaultVirtualizationEngine HyperV

#make the network definition
Add-LabVirtualNetworkDefinition -Name $labName -AddressSpace <IP_ADDRESS>/24

Set-LabInstallationCredential -Username Install -Password Somepass1

#and the domain definition with the domain admin account
Add-LabDomainDefinition -Name test1.net -AdminUser Install -AdminPassword Somepass1

#the first machine is the root domain controller. Everything in $labSources\Tools get copied to the machine's Windows folder
Add-LabMachineDefinition -Name S2DC1 -Memory 512MB -Network $labName -DomainName test1.net -Roles RootDC `
    -ToolsPath $labSources\Tools -OperatingSystem 'Windows Server 2012 R2 Datacenter (Server with a GUI)'

#the second just a member client. Everything in $labSources\Tools get copied to the machine's Windows folder
Add-LabMachineDefinition -Name S2Client1 -Memory 512MB -Network $labName `
    -DomainName test1.net -ToolsPath $labSources\Tools -OperatingSystem 'Windows 10 Pro'

Install-Lab

Show-LabDeploymentSummary -Detailed

```

repository: AutomatedLab/AutomatedLab

path: /Help/Wiki/SampleScripts/HyperV/en-us/SmallLab 2012R2 Single Client.md

branch_name: refs/heads/develop

filename: SmallLab 2012R2 Single Client.md

gha_language: PowerShell

repo_name: AutomatedLab/AutomatedLab


text:
---
layout: default
title: OpenHack - Pittsburgh
---

## Pittsburgh

### Open. Hack. Night. Pittsburgh.

![January 2013 OpenHackPGH](/pittsburgh/images/2013-01/general-talking.jpg)

Jointly presented by [PGHPython](http://pghpython.org/) and [pghrb](http://pghrb.org)
OpenHack Pittsburgh is held on the fourth Monday of every month, from 6:00-9pm.

- *Open* - OpenHack is open to anyone, regardless of technology or skill
- *Hack* - The only goal is to create something together and have fun doing it
- *Night* - Meetings are timeboxed to create a sense of purpose and a reason to follow up at the bar after ;)
- *Pittsburgh* - We believe the technology community in this city is a sleeping giant dying for this

Follow us on Twitter for timely updates: [@OpenHackPGH](http://twitter.com/OpenHackPGH)

### Meetings

**March 25, 2013**

6:00pm at The Beauty Shoppe's new event space 6101 Penn ave, PGH PA 15206

### Previous Meetings

- [February 25, 2013](#)
- [January 21, 2013](http://www.meetup.com/pittsburgh-ruby/events/96033112/)

### Contact

Contact us on Twitter or by email to inquire about hosting or sponsorship opportunities.

- [Twitter](http://twitter.com/OpenHackPGH)
-<EMAIL_ADDRESS>
### Pictures

extension: markdown


text:
![fritz2](https://www.fritz2.dev/images/fritz2_logo_grey.png)

# Spring TodoMVC

This project is an example for using [fritz2](https://www.fritz2.dev/) with in a spring boot-web application.
It will demonstrate how-to interact with a backend application in fritz2 and how-to setup this kind of project.

This project consists of two sub-projects "app" and "backend".
The "app" project is a kotlin multi platform project which contains the client-site model and application.
The "backend" project is the spring boot 2 web-application and contains all the server-side code.
For using some shared parts of the "app" the "backend" has a dependence to the `commonMain` section of the "app" project.

This project uses the following libraries:
* [fritz2](https://github.com/jwstegemann/fritz2) - mainly in "app", except validation and model in both sides
* [kotlinx.serialization](https://github.com/Kotlin/kotlinx.serialization) - currently, only in "app" because there is no official support for spring web yet
* [Spring Framework](https://start.spring.io/) - by using Spring Boot, Spring Web, Spring Data JPA in "backend"
* [H2 Database](https://www.h2database.com/html/main.html) - running as in-memory-db which stores the data

# Current status
What is currently there:
* running full-stack-example based on the [TodoMVC](http://todomvc.com/)
* working validation provided by fritz2 extension on client- and server-side
* complete gradle configuration
* some tests

# Run
To run this application you only need to run the following gradle task:
```
> gradlew bootRun
```
Then navigate in your browser to [localhost:8080](http://localhost:8080/)

# Build
You can build a runnable fatJar by running the `bootJar` gradle task.
If you instead want to deploy this application to a Java web server you
can run the gradle `bootWar` task to get a war file.

Both files are then located at the `./backend/build/libs` folder.

# Contribution
If you like this example and how fritz2 works it would be great
when you give us a ⭐ at our [fritz2 github page](https://github.com/jwstegemann/fritz2).

When you find some bugs or improvements please let us know by reporting an issue
[here](https://github.com/jamowei/fritz2-spring-todomvc/issues).
Also, feel free to use this project as template for your own applications.


text:
### [CVE-2008-6427](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2008-6427)
![](https://img.shields.io/static/v1?label=Product&message=n%2Fa&color=blue)
![](https://img.shields.io/static/v1?label=Version&message=n%2Fa&color=blue)
![](https://img.shields.io/static/v1?label=Vulnerability&message=n%2Fa&color=brighgreen)

### Description

SQL injection vulnerability in index.php in Hivemaker Professional 1.0.2 and earlier, when magic_quotes_gpc is disabled, allows remote attackers to execute arbitrary SQL commands via the cid parameter.

### POC

#### Reference
- http://e-rdc.org/v1/news.php?readmore=91
- https://www.exploit-db.com/exploits/5698
- https://www.exploit-db.com/exploits/5928

#### Github
No PoCs found on GitHub currently.

repository: trickest/cve

gha_language: HTML

repo_name: trickest/cve


text:
# server-deployment-practice

Simple express server with two routes that responds with a 'hello World' and timestamp.

## Deployment
- Production: https://tekjones-server-deploy-prod.herokuapp.com/
- Development: https://tekjones-server-deploy-dev.herokuapp.com/

![express app](./express-app.jpg)

## Routes

### /
- no parameters
- String response 'Hello World'

### /data
- no parameters
- json response {
    10: "even",
    5: "odd",
    "time": req.timestamp // we got this from the middleware
  }

repository: Tekthree/server-deployment-practice

gha_language: JavaScript

repo_name: Tekthree/server-deployment-practice


text:
Rediclus
========

*a learning exercise*

A simple Redis clone written in Clojure.  It implements the `get` and `set`
commands using the Redis TCP protocol.

Running
-------

    $ lein run

    # Or to run on a certain port
    $ lein run 12345

Usage
-----

Start the server and then open the `redis-cli` console and start playing:

    $ redis-cli
    $ redis <IP_ADDRESS>:6379>
    $ redis <IP_ADDRESS>:6379> set name honza
    $ OK
    $ redis <IP_ADDRESS>:6379> get name
    $ "honza"

Benchmark
---------

Non-parallel get requests in ms:

    Iterations:      5000
    95th percentile: 0.241041183472
    99th percentile: 0.285148620605
    min:             0.165939331055
    max:             1.68514251709

License
-------

BSD, short and sweet

repository: honza/rediclus

repo_name: honza/rediclus


text:
### i10n_pagewise

The example in the packages i10n_pagewise shows you how to use the
i10n_hierarchy_generator to build an Flutter application.

The translations are organized by page and all possible forms of translations are shown.

Please study the README.md in [i10n_pagewise](.\i10n_pagewise) carefully.

gha_language: Dart


text:
> Difference between machine learning and AI:
> If it is written in Python, it's probably machine learning
> If it is written in PowerPoint, it's probably AI
>
> Mat Velloso

---
# In this class
* Binary Classifiers
    * Logistic Regression
    * Decision Trees
    * Simple Artificial Neural Networks

---

# Road Map
* Basic Concepts
* Supervised Learning
* Logistic Regression

---
# An Example Application
* A hospital puts a baby monitor on a newborn they measure 17 variables (blood pressure, age, heartrate)
* ***A decision is needed:*** whether to alert the nurses of distress.
* Solution: based on data from other infants where were in distress they used a classifier to alert the nurses.

---
# Two Flavors Classifiers
* **Binary Classifiers** - Classifies between 2 things
* Multi-class Classifiers - Classifies between many things

![full](https://microshak.github.io/MicroNotes/Images/ML/binarVSmulticlass.png)

---

# Classifiers work on
* Data
* Images
* Sound
* Video

---

# Regression
* **Regression analysis** is a statistical process for estimating the relationships among dependent and independent(predictor) variables.

* Can be used for:
  * Inferring causal relationship
  * Predictions
  * Forecasting

---
# Linear Regression

![full](https://microshak.github.io/MicroNotes/Images/ML/linearregression.jpg)

---
# Logistic Regression
![full](https://microshak.github.io/MicroNotes/Images/ML/logisticregression.png)

---
# Logistic Regression
* When you need to make a binary decision
* Great when the data is simple
* Great as a base line for other ML algorithms
* One of the most commonly used algorithms for Binary Classification

---
# In Class Exercise
[Exercise](https://github.com/Microshak/Databricks/blob/master/SmartData/LogisticRegression.dbc)
![full](https://microshak.github.io/MicroNotes/Images/Mike/Providence.png)

---

# Algorithm Score

* **Accuracy:** measures the goodness of a classification model as the proportion of true results to total cases.

* **Precision :** proportion of true results over all positive results.

* **Recall:** is the fraction of all correct results returned by the model.

* **F-score** is computed as the weighted average of precision and recall between 0 and 1, where the ideal F-score value is 1.

* **Support** the number of samples of the true response that lie in that class.

---
# Algorithm Score

* **ROC (Receiver Operating Characteristics) Curve** is created by plotting the true positive rate against the false positive rate.

* **AUC** measures the area under the curve plotted with true positives on the y axis and false positives on the x axis. This metric is useful because it provides a single number that lets you compare models of different types.

* **Average log loss** is a single score used to express the penalty for wrong results. It is calculated as the difference between two probability distributions – the true one, and the one in the model.

* **Training log loss** is a single score that represents the advantage of the classifier over a random prediction.

---

# In class Exercise

[Exercise](https://github.com/Microshak/Databricks/blob/master/SmartData/DecisionTree.dbc)
---

# Precision
### **Precision** attempts to answer the following question:
> What proportion of positive identifications was actually correct?

```math
Precision = TP/(TP+FP)
```

---
# Recall
### **Recall** attempts to answer the following question:

> What proportion of actual positives was identified correctly?

```math
Recall = TP/(TP+FN)

```

---

# When to use Accuracy vs Precision and Recall

Accuracy bad in unbalanced datasets.

Use Precision and Recall

```txt
What is an unbalanced dataset?
Total Observations = 1000
Fraudulent  Observations = 20
Non Fraudulent Observations = 980

Event Rate= 2 %

```

---

# Should I use Precision or Recall?

* F1 score waited Precision vs Recall equally
* F1 score is the harmonic average of Precision and Recall
* 1 is best
* 0 is worst

---
# Confusion Matrix
Predicted label and true label

|                | Class 1 Predicted | Class 2 Predicted |
|:--------------:|:-----------------:|:-----------------:|
| Class 1 Actual | TP                | FN                |
| Class 2 Actual | FP                | TN                |

---
# Three Things
* Logistic regression is a good choice when:
    * You have a simple data set
    * You need a binary decision
    * When you want to predict something or gain further insights on data
* To make a binary Classifier you need to:
  * Preparing the data
  * Performing the classifier
  * Judging the results
* Understanding your tolerance for TP, FN, FP, TN can help you choose the right classifier

---
# In this section
* Decision Trees
* Random Forrest
* Roc Curves/AUC

---
# Decision Trees

* Binary Classifier
* Use when the data is complex

---
# Radial Boundary Data Set
![left](https://microshak.github.io/MicroNotes/Images/ML/lr_boundary_radial.png)
![right](https://microshak.github.io/MicroNotes/Images/ML/model_boundary_radial.png)

---
# Linear Boundary Data Set
![left](https://microshak.github.io/MicroNotes/Images/ML/lr_boundary_linear.png)
![right](https://microshak.github.io/MicroNotes/Images/ML/model_boundary_linear.png)

---
# ROC Curve/AUC

When making a prediction for a binary or two-class classification problem, there are two types of errors that we could make.

False Positive. Predict an event when there was no event.
False Negative. Predict no event when in fact there was an event.

> True Positive Rate = True Positives / (True Positives + False Negatives)

> False Positive Rate = False Positives / (False Positives + True Negatives)

Sensitivity = True Positive Rate
Specificity =  False Positive Rate

---
<iframe src="docs/roc.html" style="height:600px;">
</iframe>
---

# Random Forrest
* Random forests is a set of multiple decision trees.
* Deep decision trees may suffer from overfitting, but random forests prevents overfitting by creating trees on random subsets.
* Decision trees are computationally faster.
* Random forests is difficult to interpret, while a decision tree is easily interpretable and can be converted to rules.

---

# Overfitting/Underfitting
![full](https://microshak.github.io/MicroNotes/Images/ML/overunder.png)

---

# Other methods
* ML on the images directly [link](https://www.pyimagesearch.com/2019/02/18/breast-cancer-classification-with-keras-and-deep-learning/)
* Principle Component Analysis (PCA) [link](https://towardsdatascience.com/dive-into-pca-principal-component-analysis-with-python-43ded13ead21)
* K-Nearest Neighbor [link](https://www.kaggle.com/georgiost77/breast-cancer-machine-learning-prediction)
* Deep Learning

---

# Three Things
* Decision Trees can help classify a problem when data is complex
* There are different types of decision trees such as Random Forests with different characteristics.
* ROC Curve/AUC can help you determine the your threshold for false positive and false negatives
---
# In this Section
* Deep Learning
* Artificial Neural Networks
  * Activation Functions
  * Drop Out
  * Sparse/Dense
 * Tensorflow
 * Types of artificial Neural Networks

---
# History of Machine Learning

* 1950 - Touring Test
* 1951 - First AI Program
* 1955 - First AI Game play created
* 1958 - first [Preceptron](https://en.wikipedia.org/wiki/Perceptron) and Activation

---
# Neural Networks
### Artificial Neural Networks are roughly based on our brains Neural Network.
* Multi Node are interconnected
* Signals can pass through these nodes
* Has a hierarchical structure
* When we model rules on computers we get similar results to humans
---
![full](https://microshak.github.io/MicroNotes/Images/ML/Neuronanimation.gif)
---

![full](https://microshak.github.io/MicroNotes/Images/ML/simple.gif)
---
![left](https://microshak.github.io/MicroNotes/Images/ML/neural_network.png)
---
![left](https://microshak.github.io/MicroNotes/Images/ML/Mark_I_perceptron.jpeg)
---
#### RULES
1. Start off with a Perceptron having random weights and a training set
2. For the inputs of an example in the training set, compute the Perceptron’s output
3. If the output of the Perceptron does not match the output that is known to be correct for the example: * If the output should have been 0 but was 1, decrease the weights that had an input of 1. * If the output should have been 1 but was 0, increase the weights that had an input of 1.
4. Go to the next example in the training set and repeat steps 2-4 until the Perceptron makes no more mistakes

---
#### Rules more simply
1.  Input X Weights + Bias
2.  Apply Activation Function
3.  Pass Value to Next Layer
4.  On Final Layer find errors and Update Weights of previous layers

---

# Activation Function
### Problem with Machine Learning
Any Series of matrix multiplication can be condensed down to one matrix multiplication.

Activation Functions are non linear functions that prevent condensing.

Must complex data has non linearity

---
# Activation Function  - Sigmoid
Takes some number and squashes it between 0 and 1.
0 means no fire
1 means fire

 **Problems with Sigmoid Functions**
 1. Causes vanishing gradient (makes no data fill fire)
 2. Causes exploding gradients(makes all data fire)

---
# Activation Function  -  TanH
* Squashes the number between 1 and -1
* Easier to train than Sigmoid but also has the vanishing gradient problem

---
# Activation Function  -  ReLU (Rectified Linear Unit)
* Popular
* Simple
* Fast
* Rules
  * Linear where X is > 0
  * 0 when X > 0
* Avoids vanishing gradient problem
* Simple but has a 6X improvement over Tanh on Imagenet classification.
* Has many variations
* **Only used for hidden layers**
---
# Activation Function  -  Leaky ReLU
* Issue on ReLu negative numbers turn into 0.  A large update can make the neuron die.  No activation.
* Leaky ReLU introduces a small slope to keep the update alive
  ![full](https://microshak.github.io/MicroNotes/Images/ML/leakyrelu.png)

---

# Activation Function  -  SoftMax
* Squishes values between 0 and 1 like Sigmoid
* Makes sure all output values sum up to 1
* **Generally used for Output layers doing classification**
  ![full](https://microshak.github.io/MicroNotes/Images/ML/softmax.png)
---

# Drop Out
* Drop some data on each training loop which
  * Prevents over fitting
  * Encourages all the use of all nodes
---

# Loss Functions
A method of evaluating how well your algorithm models your dataset
May different types of Loss functions depending on what you are doing

* Mean Squared Error - Common evaluation takes difference between predictions and data
* Cross Entropy - Tries to minimize the entropy/prevents overfitting

---

#Optimizer
While Loss Functions tell you how far you are off Optimizer tell you how to reduce errors.
  ![full](https://microshak.github.io/MicroNotes/Images/ML/problematicOptomizer.gif)

Different way of surveying the land and pushing through local issues.

---

# Matrices
If there is a lot of 0s in your data then it is **Sparse**.

Else it is **Dense**

---
# Exercise
[Exercise](https://github.com/Microshak/Databricks/blob/master/SmartData/SimpleNeuralNetwork.dbc)

### Bonus
[Tensorflow Playground](https://playground.tensorflow.org/#activation=relu&batchSize=10&dataset=spiral&regDataset=reg-plane&learningRate=0.001&regularizationRate=0&noise=0&networkShape=8,7,7,5,2&seed=0.30542&showTestData=false&discretize=false&percTrainData=50&x=true&y=true&xTimesY=true&xSquared=true&ySquared=true&cosX=false&sinX=true&cosY=false&sinY=true&collectStats=false&problem=classification&initZero=false&hideText=false)

---

# Regularization
Helps solve overfitting issue by penalizing your loss function by adding a multiple of L1 LASSO or L2 Ridge to weights.

---
# Learning Rate
* Learning rate controls how quickly or slowly a neural network model learns a problem.
* How to configure the learning rate with sensible defaults, diagnose behavior, and develop a sensitivity analysis.
* How to further improve performance with learning rate schedules, momentum, and adaptive learning rates.
---
# Learn More
* [ML Cheatsheet](https://ml-cheatsheet.readthedocs.io/en/latest/)
* [Awesome List](https://github.com/ChristosChristofidis/awesome-deep-learning)
* Ean Goodfellow's [Book](https://www.deeplearningbook.org)
* Andrew NG [Course](https://www.coursera.org/learn/machine-learning?utm_source=gg&utm_medium=sem&utm_content=07-StanfordML-US&campaignid=685340575&adgroupid=32639001341&device=c&keyword=coursera%20machine%20learning%20course&matchtype=b&network=g&devicemodel=&adpostion=1t1&creativeid=243289762778&hide_mobile_promo&gclid=Cj0KCQjww47nBRDlARIsAEJ34bk0cRqeO-zp-6v__lKcxMmY55uKAJQveZWzwerrUfMShH_6yWto_SUaAlxrEALw_wcB)


text:
## GffCompare
* compare and evaluate the accuracy of RNA-Seq transcript assemblers (Cufflinks, Stringtie).
* collapse (merge) duplicate transcripts from multiple GTF/GFF3 files (e.g. resulted from assembly of different samples)
* classify transcripts from one or multiple GTF/GFF3 files as they relate to reference transcripts provided in a
annotation file (also in GTF/GFF3 format)

The original form of this program is also distributed as part of the Cufflinks suite, under the name "CuffCompare"
(see manual: http://cole-trapnell-lab.github.io/cufflinks/cuffcompare/). All the options and parameters of CuffCompare
are supported by GffCompare (for now), while new features will likely be added to GffCompare in the future.

This package only depends on my other code library, [GCLib](../../../gclib). In order to build GffCompare from this source package
the following steps can be taken:
```
  cd /some/build/dir
  git clone https://github.com/gpertea/gclib
  git clone https://github.com/gpertea/gffcompare
  cd gffcompare
  make
```
This should build the **gffcompare** binary in the current directory.

repository: roryk/gffcompare

repo_name: roryk/gffcompare


text:
# AREA Research Agenda Repository README

## Content

This folder contains all files for the AREA Research Agenda 2021

* AREA-Research-Agenda-2021.adoc - the main Research Agenda document with references to all sections
* remaining adocs - each section of the Research Agenda document is in a separate document: follow directions in each document to populate
* figures - figures used in the AREA-Research-Agenda-2021.adoc
* images - images used in the AREA-Research-Agenda-2021.adoc go here. Image files for figures go in the "figures" directory. Only place in here images not used in figures (e.g., as parts of tables, as logos, etc.)

## Building

To produce the HTML of the Research Agenda 2021 run `asciidoctor -r asciidoctor-bibliography --safe -a data-uri -o
AREA-Research-Agenda-2021.html AREA-Research-Agenda-2021.adoc`

To produce the PDF of the Research Agenda 2021 run `asciidoctor-pdf --safe -o
AREA-Research-Agenda-2021.html AREA-Research-Agenda-2021.adoc`


text:
# ARC_Omniglot
The Attentive Recurrent Comparator (ARC) catches the difference between two characters in the same way that humans do: by iteratively glancing between the images.

## Please see fellowship_submission.ipynb for analysis

## To run the model

0. update pytorch to 0.4.1. Do this if you have conda:
    - conda config --add channels soumith
    - conda update pytorch torchvision
1. download the current repo
2. [download omniglot.npy and omniglot_strokes.npz from here and place it under ./data/](https://drive.google.com/drive/folders/1uGDPpuOy-PXm-Mif3mrnUewGJthkP79A?usp=sharing)
    - omniglot.npy is equivalent to vertically stacking the background and evaluation datasets from Brendan Lake's Omniglot repo
3. run:
   python ARC/train.py --name model

   to continue training and read classification accuracies on test set.


text:
# 100DaysOfMLCode

## Day 1: Text preprocessing
- Like any data science problem, understand the questions that are being asked will inform what steps may be employed to transform words into numerical features that work with machine learning algorithms.
- None of the magic described above happens without a lot of work on the back end
- We have to spend more time in cleaning the data to get better results.
- Cleaning consist of getting rid of the less useful parts of text through stopword removal, dealing with capitalization and characters and other details.
- I have created a demo example to preprocess text.
- Link to the module: [Text preprocessing](https://github.com/udaylunawat/100DaysofMLCode/blob/master/Day%200/Text_prep.ipynb)

repository: udaylunawat/Machine-Learning

path: /Topics/9. Text analysis/README.md

repo_name: udaylunawat/Machine-Learning


text:
About
=====

nim-rss is a Nim module for working with RSS.

Installation
============

Add the following to your `{project}.nimble` file:

    requires "rss >= 1.1"

Usage
=====

`getRSS(url: string): RSS`
fetch and parse an RSS feed from a URL

`loadRSS(filename: string): RSS`
read and parse a local RSS file

`parseRSS(data: string): RSS`
parse RSS directly from a string

License
=======

nim-rss is released under the MIT Open Source License.

repository: OldhamMade/nim-rss

repo_name: OldhamMade/nim-rss


text:
# Szeth

> I am Truthless. I do as my master requires and I require no explanation.

**Szeth**, formerly **Szeth-son-son-Vallano** or **Szeth-son-Neturo**, Truthless of #[Shinovar](locations/shinovar), is a Shin man from Roshar. He is the infamous Assassin in White and is responsible for the death of #[Gavilar Kholin](characters/gavilar) kickstarting the War of Reckoning. As the Assassin, he wields Jezrien's Honorblade; eventually, he loses it, and is gifted Nightblood.

Szeth is currently a Skybreaker of the Third Ideal and serves #[Dalinar Kholin](characters/dalinar). He intends to return to Shinovar and bring justice to the ones who exiled him as his Fourth Skybreaker Ideal quest.

repository: jofwu/roshar-map

repo_name: jofwu/roshar-map


text:
# Description
Provides a mechanism for installing a Flume agent.

# Compatability

As of version 1.2, this has been validated to work on Chef 12.5.1.

# Providers

The following are a list of provided actions supplied by this cookbook.

## Create

This provider is enabled using the _:create_ action. It will install a Flume agent of your choosing. An example invocation might look like:

<pre>
# Install the Flume agent
flume_agent "my-agent" do
  action :create
  userName "flume"
  userGroup "flume"
  agentName "my-agent"

  postStartupScript do
    cookbook_filename "startup_hook_script.sh.erb"
  end

  loggingProperties do
    cookbook_filename "flume.log4j.properties.erb"
  end

  configFile do
    cookbook_filename "flume.properties.erb"
    variables(:my-arg => "a", :my-arg2 => "b")
  end

  flumePlugin "my-flume-plugin" do
    file "/usr/share/flume/my-flume-plugin.tar.gz"
  end

  flumeEnv do
    cookbook_filename "my-flume-env.sh.erb"
  end

  jmx do
    port 1234
  end

  rmLib "guava-10.0.1.jar"
end
</pre>

This takes, at a minimum, four parameters:

* **userName**: The name of the user under which this installation is to occur
* **userGroup**: The group to which the installation is to be long
* **agentName**: The name of the agent to be installed
* **configFile**: The configuration file to be used to direct the behavior of the Flume agent. This is described in further detail below.

Optionally, you may also specify the following parameters:

* **flumeArchiveUrl**: The URL link to the Flume binaries used to set up the runtime environment.

### Configuration Providers

Nested within the provider are configuration elements that contain their own parameters.

#### configFile

This is a required element of your provider configuration. It tells Flume how to configure the agent it is going to install and start. It accepts the following parameters:

* **cookbook_filename**:  The name of the file stored in the cookbook to be copied (as a template)
* **cookbook**: _(optional)_ The name of the cookbook from which the file is to be copied; defaults to the cookbook calling the provider
* **variables**: _(optional)_ A hash of variables to be provided to the copied agent configuration file.

#### loggingProperties

Flume provides its own default logging configuration, but, if you so choose, you can provide your own log configuration. This should be a log4j configuration file. It accepts the following parameters:

* **cookbook_filename**: The name of the file stored in the cookbook to be copied (as a template)
* **cookbook**: _(optional)_ The name of the cookbook from which the file is to be copied; defaults to the cookbook calling the provider
* **variables**: _(optional)_ A hash of variables to be provided to the copied logging properties file.

#### flumePlugin

Flume supports a style of packaging up libraries to be provided as "plugins" to the Flume installation. Refer to the [Flume documentation](http://flume.apache.org/FlumeUserGuide.html#installing-third-party-plugins) for more details on the exact packaging contents. This cookbook expects all plugins to be packaged as a .tar.gz file.

At minimum, one of the following sources must be provided:

* **url**: A URL from which the .tar.gz file will be downloaded.
* **file**: A location on the local disk from which the .tar.gz file will be copied
* **cookbook_filename**: The name of a cookbook file that will be copied as the .tar.gz file.
    * Optionally, the **cookbook** parameter can be specified here to identify which cookbook the file should be copied. If not specified, it will be the name of the cookbook calling the provider.

The expected format of the provided Flume plugin bundle follows:

    my-project-1.0-my-plugin-flume-plugin.tar.gz
      |
      +- name-of-my-plugin
          |
          +- lib/
          |   |
          |   +- my-lib.jar
          +- libext/
              |
              +- a.jar
              +- b.jar

#### flumeEnv

Use this element to provide a <tt>flume-env.sh</tt> file template to be copied into the Flume installation. It takes the following parameters:

* **cookbook_filename**: The name of the file stored in the cookbook to be copied (as a template)
* **cookbook**: _(optional)_ The name of the cookbook from which the file is to be copied; defaults to the cookbook calling the provider
* **variables**: _(optional)_ A hash of variables to be provided to the copied logging properties file.

#### postStartupScript

Starting with version 1.0.7 of this cookbook, the provider now provides a hook allowing consumers to specify a shell script to be executed following the startup of the agent. This allows the injection of, for example, the execution of a health check to ensure that the agent is available. It takes the following parameters:

* **cookbook_filename**: The name of the file stored in the cookbook to be copied (as a template)
* **cookbook**: _(optional)_ The name of the cookbook from which the file is to be copied; defaults to the cookbook calling the provider
* **variables**: _(optional)_ A hash of variables to be provided to the copied script

#### jmx

This block enables JMX reporting of the behavior of the agent. It takes the following parameter:

* **port**: The port on which the agent will publish its JMX statistics.

#### rmLib

(since 1.1) Flume plugins do not get loaded in classloaders isolated from the main classpath of the Flume agent; as a result, dependency convergence issues can arise (such as Guava incompatibilities). To help with this, the option is given as part of this cookbook to have it remove libraries from `lib/` directory beneath the Flume installation directory.

### Registered service

With this command, the agent will also install an _/etc/init.d/_ script following the pattern of "/etc/init.d/flume\_<agentName>". It supports the following commands:

* start
* stop
* restart
* status

gha_language: Ruby


text:
# 10 Ext JS to React: Features and Plugins (grid)

In the following examples we show how to use [ag-Grid](https://www.npmjs.com/package/ag-grid) to create a React grid with cell renderers, column locking, cell editing, and infinite scrolling

## Example Projects

 - [a-controlling-cell-data](./a-controlling-cell-data): grid example with a  cell renderer on one column used to modify the output of the data passed in
 - [b-column-locking](./b-column-locking): column locking grid example
 - [c-cell-editing](./c-cell-editing): cell editing grid example
 - [d-custom-editor](./d-custom-editor): cell editing grid example with a custom editor field
 - [e-infinite-scrolling](./e-infinite-scrolling): grid example with infinite scrolling enabled

### Related Blog Article

[Ext JS to React: Features and Plugins](https://moduscreate.com/blog/ext-js-react-features-plugins/)

repository: mitchellsimoens/extjs-reactjs-examples

repo_name: mitchellsimoens/extjs-reactjs-examples


text:
---
layout: post
title: "Write your mobile app once and run it anywhere with Ionic Framework"
excerpt: "Hybrid mobile development with HTML5, AngularJS and Cordova"
tags: [ionic, ionicframework, mobile, javascript, angularjs, cordova, phonegap, html, css, sass]
date: 2016-02-22T08:15:08-01:00
comments: true
image:
  feature: posts/cover-ionic.png
---

I've been developing some apps using the [Ionic Framework](http://ionicframework.com/) since December 2014 and it has been interesting to watch the evolution of the framework during this time and the platform that Drifty (the company behind Ionic) has been building around it ever since. In this post I'll introduce you to this very nice tool that you can also consider for your projects.

About Ionic
-----------

Ionic is a free and open source framework that allows you to build your mobile apps with [AngularJS](https://angularjs.org/), HTML5, CSS and [Apache Cordova](https://cordova.apache.org/). It offers a library of mobile-optimized HTML, CSS, JavaScript, CSS components and tools for building higly interactive apps and it's built with [SASS](http://sass-lang.com/) and AngularJS. This is called hybrid mobile development, which is when you can develop your code once and then compile packages for more than one platform, such as Android or iOS, and they're neither native nor purely web-based, but a mix of both. Your app runs inside of a webview and uses Cordova to interface with the phone's operating system.

It's a good option if you consider that you'll have one code that will run on many platforms, so you'll need just JavaScript developers on your team, instead of specific developers for Android and specific developers for iOS. Two separate teams, two different codes, more bugs to deal with, everything twice.

Cordova
-------

![Cordova](/images/posts/cordova.jpg "Cordova")

This is the open source software used by Ionic to manage and generate apps for different kinds of platforms and to allow the Ionic app to communicate with the device. So Ionic works as a wrapper for Cordova and Cordova has many plugins to extend its functionalities. The plugins offer JavaScript interfaces to native components on your device, allowing your app to use native device capabilities beyond what is available to pure web apps. For example, there are plugins for scanning QRCode, for working with push notifications or accessing your device's camera.

ngCordova
---------

![ngCordova](/images/posts/ngcordova.png "ngCordova")

At Ionic's website, they recommend the use of [ngCordova](http://ngcordova.com/) (Angular powered by Cordova), which is a collection of [70+ AngularJS extensions](http://ngcordova.com/docs/plugins/) (wrappers) on top of the Cordova API that make it easy to build, test, and deploy Cordova mobile apps with AngularJS.

For example, there's a plugin you can add to your project and with a few lines of code, use it to access your device's camera and retrieve a photo as a base64-encoded image.

```
$ cordova plugin add cordova-plugin-camera
```

There's also a plugin for OAuth, another for Geolocation, SMS, etc.

Ionicons
--------

![Ionicons](/images/posts/ionicons.jpg "Ionicons")

This is the name of the icon font that comes with Ionic, also free and open source. If you want to implement a close button on your app, for example, you just have to use the class "ion-close" inside of an element:

```
<p><i class="icon ion-close"></i> Close</p>
```

Check [here](http://ionicons.com/) the list of icons they have available

Ionic CLI
---------

Ionic comes with a command line utility that makes it easy for you to do many tasks, such as start, build, run and emulate Ionic apps.

You can use it to run a live reload server, so your app runs on your browser while you modify it from your IDE or Code Editor, such as [Brackets](http://brackets.io/) (The one I've been using and really enjoying), and your modifications appear automatically on the browser without the need to refresh the page.

```
$ ionic serve
```

You can also use this utility to [generate icon and slash screen images](http://ionicframework.com/docs/cli/icon-splashscreen.html), provide information about your runtime, upload your app to be viewed on Ionic View, among other things.

Ionic View
----------

In this [Ionic service](http://ionicframework.com/docs/cli/uploading_viewing.html) you can upload your app to their servers using the CLI utility and then view it on the Ionic View app installed on your device, Android or iOS. You have to [create an account](http://apps.ionic.io/signup) and then you can have many apps listed on your device with the option to synchronize them to new versions when you release them. It certainly saves you from the hassle of having to go through all the bureaucracy to test your apps on an Apple device, for example. It's also interesting for showing new features to your clients, who just need to have the Ionic View app on their devices.

Ionic Creator
-------------

The Ionic team created this [very useful service](http://ionic.io/products/creator) where you can make prototypes of your apps by dragging and dropping components and then export the code or the packages for each platform. As if it was not enough, they also created a mobile app for the Ionic Creator, where you can watch the changes in real time, as they get synchronized automatically and test your mobile app on your device instead of on your browser.

In [this post](http://blog.ionic.io/announcing-the-new-ionic-creator/) from their blog you can read more about it.

Conclusion
----------

If you're looking to develop mobile apps for your company in a simple way and your apps won't need very specific resources from the native platforms, I can certainly recommend you Ionic Framework. It's fast, the code is clean and it offers everything you need for your mobile app development. It's not only a product, but a whole platform with many services being developed by Drifty and has a bright future.

You can find the source code of the [Ionic Framework on Github](https://github.com/driftyco/ionic)


text:
[com.github.salomonbrys.kodein.android](../index.md) / [ActivityInjector](index.md) / [kodeinScope](.)

# kodeinScope

`open val kodeinScope: `[`AndroidScope`](../-android-scope/index.md)`<Activity>`

Overrides [AndroidInjector.kodeinScope](../-android-injector/kodein-scope.md)

The scope that this component belongs to (for internal use only)

**Getter**

The scope that this component belongs to (for internal use only)

repository: suclike/Kodein

repo_name: suclike/Kodein


text:
FacebookPlaylist
================
This script will read a Facebook feed (event feed, user feed, etc.) and tries to find YouTube links on the status updates. In case a status update has a YouTube URL, the script will attempt to download the file, extract the audio and queue the song in Clementine.

Why?
====
I was planning to make a party, I wanted to let people decide what to listen to and this seemed to be a good thing to do.

What's missing?
===============
Post a reply on the status saying "The server queued this song, thanks!"

Dependencies
============
Ideally you'll use Composer. Checkout this repo and run composer install.
Also install youtube-dl avconv php5-cli and may be Redis.

How to use
==========
Set your own AppKey, Secret and Event Id in the Config file. The Event Id can be obtained from the Event URL in Facebook.

Run the file readSongs.php every often. Depending on how often you run it, change the setting in config.php

repository: nicoandra/FacebookPlaylist

repo_name: nicoandra/FacebookPlaylist


text:
---
title: HYCON2
summary: Highly-complex and networked control systems
tags:
- Past
date: "2019-05-29T00:00:00Z"

# Optional external URL for project (replaces project detail page).
external_link: ""

image:
  caption:
  focal_point: Smart

# links:
# - icon: twitter
#   icon_pack: fab
#  name: Follow
#  url: https://twitter.com/georgecushen
# url_code: ""
# url_pdf: ""
# url_slides: ""
# url_video: ""

# Slides (optional).
#   Associate this project with Markdown slides.
#   Simply enter your slide deck's filename without extension.
#   E.g. `slides = "example-slides"` references `content/slides/example-slides.md`.
#   Otherwise, set `slides = ""`.
slides: example
---
This project aims at stimulating and establishing a long-term integration in the strategic field of control of complex, large-scale, and networked dynamical systems. It focuses in particular on the domains of ground and aerospace transportation, electrical power networks, process industries, and biological and medical systems.

## Project team

This network of excellence has partners from France, Switzerland, Germany, Italy, the Netherlands, and Swede.

## Project funding and duration

This is a FP7 NoE with duration 2010--2014.

## Links

[Project website](http://www.hycon2.eu)

repository: hhjalmars/academic-kickstart

repo_name: hhjalmars/academic-kickstart


text:
# Space Communication Utilizing Background Existing Networks

Scubee is a senior design project between the University of Idaho and NASA ARC.

[Wiki](http://mindworks.shoutwiki.com/wiki/NASA_Ames_Suborbital_Flight_Communication)

## Building

See `CONFIG.md`

A copy of [lwIP](https://download.savannah.nongnu.org/releases/lwip/lwip-2.1.2.zip) must be downloaded and extracted to this folder before building.

### PC Version

Requirements:
* A version of `gcc` and `binutils`
* A copy of `gmake` or compatible software.

To build, simply run
```
> make -C pc
```

This will create the file `pc/scubee.elf`, which can be ran directly.  Note that the PC version of the library currently only runs on Linux and BSD.

### Microcontroller Version

Requirements:
* A version of `gcc` and `binutils` targetting `arm-none-eabi`.
* A copy of `gmake` or compatible software.

To build, simply run
```
> make -C dkm
```

This will create the file `dkm/scubee.dkm`, which can be copied directly to the microcontroller.

The PC version takes commands from `stdin` and writes responces to `stdout`.

### Cleaning

To clean the project, run either

```
> make -C dkm clean
```

or

```
> make -C pc clean
```

depending on which version was built.  Note that you have to clean the project before building a different version, to prevent cross-architecture contamination.

## Testing

### PC Version

To test the PC version, create two empty files `test_cmd` and `test_rsp`. and run

```
> ./pc/scubee.elf <test_cmd >test_rsp
```

Then write (append, not overwrite) all commands to `test_cmd`, and read all responses from `test_rsp`.

## TODO

- [ ] Port the PC version to non-Posix systems.
- [ ] Fully integrate lwIP.  Currently, we simply link it, without actually calling anything (except `lwip_init`).

## License

Scubee is released under the BSD 3-clause license, reproduced below.

> Copyright (c) 2018-2019 Hunter Barnett \< barnetthu+scubee at gmail dot com \>.
> All rights reserved.
>
> Redistribution and use in source and binary forms, with or without
> modification, are permitted provided that the following conditions are met:
>
> 1. Redistributions of source code must retain the above copyright notice, this
>    list of conditions and the following disclaimer.
>
> 2. Redistributions in binary form must reproduce the above copyright notice,
>    this list of conditions and the following disclaimer in the documentation
>    and/or other materials provided with the distribution.
>
> 3. Neither the name of the copyright holder nor the names of its contributors
>    may be used to endorse or promote products derived from this software
>    without specific prior written permission.
>
> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
> DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
> FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
> DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
> CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
> OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

lwIP is included under the BSD 3-clause license, reproduced below.

> Files: `lwip-2.1.2.zip`

> Copyright (c) 2001, 2002 Swedish Institute of Computer Science.
> All rights reserved.
>
> Redistribution and use in source and binary forms, with or without
> modification, are permitted provided that the following conditions are met:
>
> 1. Redistributions of source code must retain the above copyright notice, this
>    list of conditions and the following disclaimer.
>
> 2. Redistributions in binary form must reproduce the above copyright notice,
>    this list of conditions and the following disclaimer in the documentation
>    and/or other materials provided with the distribution.
>
> 3. Neither the name of the copyright holder nor the names of its contributors
>    may be used to endorse or promote products derived from this software
>    without specific prior written permission.
>
> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
> DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
> FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
> DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
> CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
> OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Parts of [ChromiumOS](https://chromium.googlesource.com/chromiumos/platform/ec/+/refs/heads/master/core/cortex-m0) are included under the BSD 3-clause license, reproduced below.

> Files: `dkm/chromium/div.s`, `dkm/chromium/thumb_case.s`

> Copyright (c) 2014 The Chromium OS Authors.
> All rights reserved.
>
> Redistribution and use in source and binary forms, with or without
> modification, are permitted provided that the following conditions are met:
>
> 1. Redistributions of source code must retain the above copyright notice, this
>    list of conditions and the following disclaimer.
>
> 2. Redistributions in binary form must reproduce the above copyright notice,
>    this list of conditions and the following disclaimer in the documentation
>    and/or other materials provided with the distribution.
>
> 3. Neither the name of the copyright holder nor the names of its contributors
>    may be used to endorse or promote products derived from this software
>    without specific prior written permission.
>
> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
> DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
> FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
> DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
> CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
> OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

repository: DreamKontrol/scubee

repo_name: DreamKontrol/scubee


text:
---
title: "How do I make a million dollars? (3)"
created_at: 2019-07-05T00:07:10.000Z
published_at: 2019-07-05T22:11:20.000Z
---
[@seunoyebode](https://200wordsaday.com/words/my-most-important-tab-right-now-217355d1de22598291) wrote something about how many customers he needs for his SaaS app idea in order to earn X amount, which I happened to also be brainstorming about recently. The question is: how do I make a million dollars in 12 months from a monthly subscription-based SaaS product? I wrote parts [(1)](https://200wordsaday.com/words/how-do-i-make-a-million-dollars-1-196895cfbd4776e4ff) - the why, and [(2)](https://200wordsaday.com/words/how-do-i-make-a-million-dollars-2-198345cfe58d077e02) - the what, previously, so this is a continuation.

Since I want a monthly subscription SaaS product that gives monthly recurring revenue, how much do I have to earn per month, and how many customers would that take, in order to get to $1mil? This nifty little [tool](https://hmcte.info/?amount=1000000&months=12), which @seunoyebode shared, helps break it down:

_I want to earn $1,000,000 in 12 months, hence I will need $83,333 per month, or $2,688.17 per day. So how many customers do I need?_

Get 50 people to pay $1,666/month for 12 months.

Get 100 people to pay $833/month for 12 months.

Get 200 people to pay $416/month for 12 months.

Get 500 people to pay $166/month for 12 months.

**Get 1000 people to pay $83/month for 12 months.**

Get 5000 people to pay $16/month for 12 months.

Get 10,000 people to pay $8.33/month for 12 months.

Get 100,000 people to pay $0.83/month for 12 months.

I like how this breaks it down, since it helps me see what kind of market I want to play in. Mass appeal, or a niche few? Enterprise, or consumer? B2B, or B2C?

The bottom half of the list (from 1000 people downwards) is definitely going towards mass appeal, to consumers, B2C. The last one - 80cents per month - is probably in the range of designing for extreme affordability, so it might be for a developing country market? (not necessarily so of course, but one of the possibilities). The top half of the list (50-500 people) is probably in the enterprise, B2B space, because probably only companies feel comfortable paying hundreds/thousands of dollars for a monthly subscribed SaaS product. Serving consumers vs enterprises has it's own set of pros and cons. _Which do I prefer?_

In the end, realistically speaking, it probably has to be a portfolio mix of it. [@levelsio](https://twitter.com/levelsio/status/1134089856265494528?s=21) is a great example. [Nomadlist](https://nomadlist.com/) is direct to consumer, but also runs some ads for enterprises. His job board, [Remote OK](https://remoteok.io/), is free for consumers but paid for enterprises. His [Make Book](https://makebook.io/) is for both. All in all it makes him [a million a year](https://twitter.com/levelsio/status/1134089856265494528?s=21). That's after 4 years of hard work of course.

But as a starting point, I really love Kevin Kelly's [1000 True Fans article](https://kk.org/thetechnium/1000-true-fans/). He talks about how to be a successful creator and to make a living, you don't need millions of paying customers, just **1000 true fans**:

> To be a successful creator you don’t need millions. You don’t need millions of dollars or millions of customers, millions of clients or millions of fans. To make a living as a craftsperson, photographer, musician, designer, author, animator, app maker, entrepreneur, or inventor you need only thousands of true fans.
> ...
> Here’s how the math works. You need to meet two criteria. First, you have to create enough each year that you can earn, on average, $100 profit from each true fan. That is easier to do in some arts and businesses than others, but it is a good creative challenge in every area because it is always easier and better to give your existing customers more, than it is to find new fans.
>
> Second, you must have a direct relationship with your fans. That is, they must pay you directly. You get to keep all of their support, unlike the small percent of their fees you might get from a music label, publisher, studio, retailer, or other intermediate. If you keep the full $100 of each true fan, then you need only 1,000 of them to earn $100,000 per year. That’s a living for most folks.
>
> A thousand customers is a whole lot more feasible to aim for than a million fans. Millions of paying fans is not a realistic goal to shoot for, especially when you are starting out. But a thousand fans is doable. You might even be able to remember a thousand names. If you added one new true fan per day, it’d only take a few years to gain a thousand.

Suddenly, the task doesn't feel so unreachable. One thousand fans is not something impossible. I also like how he talks about having direct relationship with them - which is something I enjoy doing as well. Even though he aims for 1000 fans paying $100 each once a year for a comfortable $100,000 income, while I'm aiming for 1000 people paying $1000 for $1mil income, the process is the same. In the back of my mind, I know $1mil is a stretch target...but hey, you know the phrase - [aim for the stars and even if you fail, you'll land on the moon](https://200wordsaday.com/words/how-do-i-make-a-million-dollars-1-196895cfbd4776e4ff).

The caveat is this probably shouldn't be the only perspective I have when it comes to thinking about what product I want to build. This is just the business perspective. More to come as I brainstorm about the other questions I listed [here](https://200wordsaday.com/words/how-do-i-make-a-million-dollars-2-198345cfe58d077e02)!


text:
## Deploying the facedetect example application

The services first need to be built and pushed to some container registry. For this we have assumed a registry hosted on gitlab, but other registries should work with low effort. First update the repository in the `apps/build_and_push.sh` script to point to a gitlab container registry that you can access. Run the script to build and push all necessary images.

```bash
chmod +x build_and_push.sh
./build_and_push.sh
```

Change the image in both `src/backend.yaml, src/frontend.yaml` to point to the correct registry/image.

Check the `settings.py` file and choose which clusters to run the frontends and backends. Deploy the application with

```bash
python3 deploy.py
```

The deployment can be removed with

```bash
python3 remove.py
```

The application can be accessed at  `http://GATEWAY_IP/api` where images can be uploaded for face detection.

#### Load generation

To generate load on the application, visit the `facedetect/load_generation` folder. Change the settings in `load_generator.py` and run it as

```
python3 load_generator.py
```

repository: frankfanslc/FedApp

repo_name: frankfanslc/FedApp


text:
# Unity Tag Selector

Simple attribute that turns a normal string field into a dropdown of all available Tags in the inspector. Never misspell the name of a tag ever again.

[![Image from Gyazo](https://i.gyazo.com/084e5e63cce91a10e6b65bf985c7a102.gif)](https://gyazo.com/084e5e63cce91a10e6b65bf985c7a102)

## Installing & Using the Attribute

- Download the source code or check the [releases on this repository](https://github.com/WSWhitehouse/Unity-Tag-Selector/releases) for a specific Unity Package download or download the [Latest Unity Package](https://github.com/WSWhitehouse/Unity-Tag-Selector/releases/latest)
  - If you downloaded the Unity Package you will need to import it. `Assets -> Import Package -> Custom Package` and select the Unity Package you just downloaded
- Put a `[TagSelector]` attribute in front of any string field. Optional bool value to change the dropdown to the default Unity Tag Dropdown

  [![Image from Gyazo](https://i.gyazo.com/809dc931cc89430d02347916646b47fc.png)](https://gyazo.com/809dc931cc89430d02347916646b47fc)

- Done! You will now have a dropdown selector which includes all of the available Tags.

repository: WSWhitehouse/Unity-Tag-Selector

repo_name: WSWhitehouse/Unity-Tag-Selector


text:
# factors_and_gcds

Created for an assignment, the program is a command line interface written in eclipse. The program asks the users for integer input and displays their factors or greatest common factor depending on the number of input arguments.

repository: tuwokHowardii/LearningJava

repo_name: tuwokHowardii/LearningJava