text:
---
page_type: sample
urlFragment: word-add-in-hello-world
products:
  - office-add-ins
  - office-word
  - office
languages:
  - javascript
extensions:
  contentType: samples
  technologies:
    - Add-ins
  createdDate: '10/11/2021 10:00:00 AM'
description: 'Create a simple Word Add-in that displays hello world.'
---

# Create an Word Add-in that displays hello world

## Summary

Learn how to build the simplest Office Add-in with only a manifest, HTML web page, and a logo. This sample will help you understand the fundamental parts of an Office Add-in.

## Features

- Display hello world in Word.
- Learn fundamentals of the manifest.
- Learn how to initialize the Office JavaScript API library.
- Interact with document content through Office JavaScript APIs.

## Applies to

- Word on Windows, Mac, and in a browser.

## Prerequisites

- Microsoft 365

## Understand an Office Add-in

An Office Add-in is a web application that can extend Office with additional functionality for the user. For example, an add-in can add ribbon buttons, a task pane, or a content pane with the functionality you want. Because an Office Add-in is a web application you must provide a web server to host the files.

The sample contained in this folder is a sample that is designed to run in Word.

### Key components

The hello world sample implements the **Manifest** and **Web app** components identified in [Components of an Office Add-in](https://learn.microsoft.com/office/dev/add-ins/overview/office-add-ins#components-of-an-office-add-in).

- Manifest: You only need one manifest file for your add-in. The hello world sample contains two manifest files to support two different hosting scenarios.
  - **manifest.xml**: This manifest file will load the add-in from the GitHub repo (through GitHub page hosting). You can run the sample and don't need to configure your own web server.
  - **manifest.localhost.xml**: This manifest file will load the add-in from a local web server that you configure. See below in this readme for instructions on configuring your own web server.
- Web app: The hello world sample implements a task pane named **taskpane.html** that contains HTML and JavaScript. The **taskpane.html** file contains all the code necessary to display a task pane, interact with the user, and write "Hello World" into the first Paragraph of the document.

### Initialize the Office JavaScript API library

The sample initializes the Office JavaScript API library with a call to `office.onReady()` in the **taskpane.html** file. This is required before you can make any calls to the Office JavaScript APIs. For more information about initialization, see [Initialize your Office Add-in](https://learn.microsoft.com/office/dev/add-ins/develop/initialize-add-in).

```javascript
Office.onReady((info) => {});
```

### Write to the document

When the user chooses the **button**, the `sayHello()` function is called. This function Then calls `Word.run` to run code and call the Office JavaScript APIs. It uses a `context` object provided by the Office JS API library to get the document body and inserts a Paragraph with the text "Hello World". Calling `context.sync()` runs the command.

For more information see [Tutorial: Create an Word task pane add-in](https://learn.microsoft.com/office/dev/add-ins/tutorials/word-tutorial)

```javascript
function sayHello() {
  return Word.run((context) => {
    // insert a paragraph at the start of the document.
    const paragraph = context.document.body.insertParagraph(
      'Hello World',
      Word.InsertLocation.start
    );

    // sync the context to run the previous API call, and return.
    return context.sync();
  });
}
```

## Run the sample on Word on web

An Office Add-in requires you to configure a web server to provide all the resources, such as HTML, image, and JavaScript files. The hello world sample is configured so that the files are hosted directly from this GitHub repo. Use the following steps to sideload the manifest.xml file to see the sample run.

1. Download the **manifest.xml** file from the sample folder for Word.
2. Open [Office on the web](https://office.live.com/).
3. Choose **Word**, and then open a new document.
4. Open the **Insert** tab on the ribbon and choose **Add-ins**.
5. On the **Office Add-ins** dialog, select the **MY ADD-INS** tab, choose **Manage My Add-ins**, and then **Upload My Add-in**.

   ![The Office Add-ins dialog with a drop-down in the upper right reading "Manage my add-ins" and a drop-down below it with the option "Upload My Add-in"](../images/office-add-ins-word-web.png)
6. Browse to the add-in manifest file, and then select **Upload**.

   ![The upload add-in dialog with buttons for browse, upload, and cancel.
](../images/office-upload-add-ins-word-web.png)
7. Verify that the add-in loaded successfully. You will see a **Hello world** button on the **Home** tab on the ribbon.
8. Choose the **Hello world** button on the Ribbon to see the Add-in Taskpane with the text "This add-in will insert the text 'Hello world!'".
9. Choose the **Say hello** button to insert "Hello World" in the document.

## Run the sample on Word on Windows or Mac

Office Add-ins are cross-platform so you can also run them on Windows, Mac, and iPad. The following links will take you to documentation for how to sideload on Windows, Mac, or iPad. Be sure you have a local copy of the manifest.xml file for the Hello world sample. Then follow the sideloading instructions for your platform.

- [Sideload Office Add-ins for testing from a network share](https://learn.microsoft.com/office/dev/add-ins/testing/create-a-network-shared-folder-catalog-for-task-pane-and-content-add-ins)
- [Sideload Office Add-ins on Mac for testing](https://learn.microsoft.com/office/dev/add-ins/testing/sideload-an-office-add-in-on-mac)
- [Sideload Office Add-ins on iPad for testing](https://learn.microsoft.com/office/dev/add-ins/testing/sideload-an-office-add-in-on-ipad)

## Configure a localhost web server and run the sample from localhost

If you prefer to run the web server and host the add-in's web files from your computer, use the following steps:

1. Install a recent version of [npm](https://www.npmjs.com/get-npm) and [Node.js](https://nodejs.org/) on your computer. To verify if you've already installed these tools, run the commands `node -v` and `npm -v` in your terminal.

2. You need http-server to run the local web server. If you haven't installed this yet you can do this with the following command:

   ```console
   npm install --global http-server
   ```

3. You need Office-Addin-dev-certs to generate self-signed certificates to run the local web server. If you haven't installed this yet you can do this with the following command:

   ```console
   npm install --global office-addin-dev-certs
   ```

4. Clone or download this sample to a folder on your computer. Then go to that folder in a console or terminal window.
5. Run the following command to generate a self-signed certificate that you can use for the web server.

   ```console
   npx office-addin-dev-certs install
   ```

   The previous command will display the folder location where it generated the certificate files.

6. Go to the folder location where the certificate files were generated. Copy the localhost.crt and localhost.key files to the hello world sample folder.

7. Run the following command:

   ```console
   http-server -S -C localhost.crt -K localhost.key --cors . -p 3000
   ```

   The http-server will run and host the current folder's files on localhost:3000.

Now that your localhost web server is running, you can sideload the **manifest-localhost.xml** file provided in the word-hello-world folder. Using the **manifest-localhost.xml** file, follow the steps in [Run the sample on Word on web](#run-the-sample-on-word-on-web) to sideload and run the add-in.

## Questions and feedback

- Did you experience any problems with the sample? [Create an issue](https://github.com/OfficeDev/Office-Add-in-samples/issues/new/choose) and we'll help you out.
- We'd love to get your feedback about this sample. Go to our [Office samples survey](https://aka.ms/OfficeSamplesSurvey) to give feedback and suggest improvements.
- For general questions about developing Office Add-ins, go to [Microsoft Q&A](https://learn.microsoft.com/answers/topics/office-js-dev.html) using the office-js-dev tag.

## Copyright

Copyright (c) 2021 Microsoft Corporation. All rights reserved.

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information, see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode<EMAIL_ADDRESS>with any additional questions or comments.

**Note**: The taskpane.html file contains an image URL that tracks diagnostic data for this sample add-in. Please remove the image tag if you reuse this sample in your own code project.

repository: ElizabethSamuel-MSFT/PnP-OfficeAddins

repo_name: ElizabethSamuel-MSFT/PnP-OfficeAddins


text:
# Advection Boundary Functional

```@meta
  CurrentModule = AdvectionEquationMod
```

This page consists of all the functions necessary for computing a boundary
functional along the geometric edges of a mesh for the advection equation.

```@autodocs
  Modules = [AdvectionEquationMod]
  Pages = ["solver/advection/boundary_functional.jl"]
```

## Functional Types

```@docs
QfluxData
IntegralQData
```

license: MIT

branch_name: refs/heads/master

extension: md

license_type: permissive


text:
---
title: Roasted Red Pepper Chipotle Pasta Salad
categories: [salad, vegan]
servings: hella
prep_time: 15
cook_time: 15
reference: https://veganbowls.com/blogs/mains/roasted-red-pepper-chipotle-pasta-salad-from-the-15-minute-vegan-meals-cookbook
ingredients:
- slug: rotini pasta
  amount: 8 oz
  notes:
- slug: avocado oil
  amount: 1/2 tbsp
  notes:
- slug: corn
  amount: 1 14.5 oz can
  notes:
- slug: kosher salt and pepper
  amount:
  notes: to taste
- slug: cherry tomatoes
  amount: 1 C
  notes:
- slug: roasted red peppers
  amount: 1/2 C
  notes: drained well
- slug: cucumber
  amount: 1/2
  notes: seedless
- slug: avocado
  amount: 1
  notes:
- slug: cilantro
  amount: 2 tbsp
  notes:
- slug: red onion
  amount: 2 tbsp
  notes: thinly sliced
- slug:  scallions
  amount: 2 tbsp
  notes: sliced, for serving
- slug:
  amount:
  notes:
- slug: vegan mayo
  amount: 1/4 C
  notes:
- slug: almond-based yogurt
  amount: 1/4 C
  notes: plain
- slug:  roasted red peppers
  amount: 1/3 C
  notes: drained well
- slug: chipotles in adobo
  amount: 1 tsp sauce from can
  notes:
- slug: lime juice
  amount: 1/2 tbsp
  notes:
- slug: kosher salt
  amount: 1 tsp
  notes:
- slug: black pepper
  amount: 1/2 tsp
  notes:
- slug: garlic powder
  amount: 1 1/4 tsp
  notes:
- slug: ground cumin
  amount: 1/2 tsp
  notes:
- slug: dried parsley
  amount: 1 tsp
  notes:

---
1.  Add the rotini, stir and cover to bring back to a boil. Remove the lid and cook to al dente, according to the package directions. Drain and rinse the pasta in cool water.

2. Place a large pan over medium-high heat. Add the avocado oil and frozen corn to the pan and season the corn with a pinch of salt and pepper. Let these cook for 4 to 5 minutes, stirring occasionally, until lightly browned. Transfer the corn to a large mixing bowl to cool.

3. Meanwhile, halve the tomatoes, chop the roasted red peppers, dice the cucumber and avocado, and finely chop the cilantro. Add these into the mixing bowl, along with the red onion, if using.

4. For the dressing, to a food processor or blender, add the mayo, yogurt, red peppers, adobo sauce, lime juice, salt, pepper, garlic powder, cumin and parsley, and blend until smooth. Add the dressing and cooked pasta into the mixing bowl, and gently stir to incorporate the dressing. Top the salad with the sliced scallions, if using.

repository: yelper/alpertopia

gha_language: SCSS

repo_name: yelper/alpertopia


text:
# So-Filipino-interpreter
This repository contains a coding project that translates words and phrases from English from one of the three dialects in the Filipino language (still editing this README.md) :
## First Interpreter - Dialect: Tagalog
### Contains :

#### Features
1. Translates English to Tagalog
2. Add a new word or phrase to dictionary

This program uses text file which contains data in dictionary format and reads it back as key, values and gives the translation for the required word. It also uses a csv module that also lets the user add a word with its translation into the dictionary.

## Second Interpreter - Dialect: Bisaya/Cebuano
### Contains :

#### Features
3. Translates English to Bisaya/Cebuano
4. Add a new word or phrase to the dictionary

This program uses text file which contains data in dictionary format and reads it back as key, values and gives the translation for the required word. It also uses a csv module that also lets the user add a word with its translation into the dictionary.

## Third Interpreter - Dialect: Waray
### Contains :

#### Features
5. Translates English to Waray
6. Add a new word or phrase to the dictionary

This program uses text file which contains data in dictionary format and reads it back as key, values and gives the translation for the required word. It also uses a csv module that also lets the user add a word with its translation into the dictionary.

#### Coded on : Visual Studio Code

#### Language used : Python 3.8

repository: ksu-is/So-Filipino-interpreter

gha_language: Python

repo_name: ksu-is/So-Filipino-interpreter


text:
# Re-brand WSO2 Identity Server UIs

From [WSO2 Identity Server 5.9.0](https://wso2.com/identity-and-access-management/) onwards, a new UI extension has been introduced to easily re-brand  basic user interfaces like the login page, username and password recovery pages, and single sign-on pages.

All these UIs are available in the **`authenticationendpoint`** and **`accountrecoveryendpoint`** web apps that are located in the `<IS_HOME>/repository/deployment/server/webapps` folder. To customize these pages, follow the steps below.

---

## Step 1: Create the extensions/branding folder

1. Navigate to the `<IS_HOME>/repository/deployment/server/webapps/authenticationendpoint` folder and create a new folder called **`extensions`**. Inside the `extensions` folder, create a new folder called **`branding`**.

2. Similarly, navigate to the `<IS_HOME>/repository/deployment/server/webapps/accountrecoveryendpoint` folder and create the folders `extensions/branding` recursively.

---

## Step 2: Create new folders for each tenant and app

To re-brand different tenants, create folders for each tenant named after the tenant domain, inside the newly created `branding` folders.
If you want to apply separate branding for each application, create folders for each application named after the application name, inside the tenant folders.

!!! note
    Application-wise branding will override tenant-wise branding.

---

## Step 3: Create the branding-preference.json file and CSS files

To customize the branding of a specific tenant or app, we need to create the `branding-preference_<locale>.json` file inside the relevant tenant or app folder.
For example, the US English branding file should be named: **`branding-preference_en_US.json`**. If you want to customize the branding for the `wso2.com` tenant, create the `branding-preference_en_US.json` file inside the `extensions/branding/wso2.com` folder.

The final folder structure should look like this:
```
extensions
└── branding
    ├── carbon.super
    │   ├── apps
    │   │   ├── peoplehr
    │   │   │   ├── stylesheets
    │   │   │   │   └── override.css
    │   │   │   ├── branding-preference_en_US.json
    │   │   │   └── branding-preference_de_DE.json
    │   │   └── salesforce
    │   │       ├── stylesheets
    │   │       │   └── override.css
    │   │       ├── branding-preference_en_US.json
    │   │       └── branding-preference_de_DE.json
    │   ├── stylesheets
    │   │   └── override.css
    │   ├── branding-preference_en_US.json
    │   └── branding-preference_de_DE.json
    └── wso2.com
        ├── apps
        │   ├── logomaker
        │   │   ├── stylesheets
        │   │   │   └── override.css
        │   │   ├── branding-preference_en_US.json
        │   │   └── branding-preference_de_DE.json
        │   └── opd-claims
        │       ├── stylesheets
        │       │   └── override.css
        │       ├── branding-preference_en_US.json
        │       └── branding-preference_de_DE.json
        ├── stylesheets
        │   └── override.css
        ├── branding-preference_en_US.json
        └── branding-preference_de_DE.json
```
To customize any other styles, you can create the `stylesheets` folder inside the tenant or app folder and add an `override.css` file to it. This file will be loaded after the default stylesheets, so you can override any styles you want.

!!! note
    Make sure to update the branding-preference.json file with the correct path to the `override.css` file.

Checkout the sample [branding-preference_en_US.json](https://github.com/wso2/docs-is/tree/master/en/docs/assets/code-samples/branding-preference_en_US.json) file and the corresponding [override.css](https://github.com/wso2/docs-is/tree/master/en/docs/assets/code-samples/override-auth.css) file for authentication portal and the [override.css](https://github.com/wso2/docs-is/tree/master/en/docs/assets/code-samples/override-recovery.css) file for recovery portal.

---

After applying the changes, refresh the browser and check out the rebranded content.

!!! tip
    Restarting the server is NOT required to reflect the changes. A browser refresh will display the changes.

-  Customized login page
![image]({{base_path}}/assets/img/extend/rebranded-ui-1.png)

- Customized recover username page
![image]({{base_path}}/assets/img/extend/rebranded-ui-2.png)

- Customized recover password page
![image]({{base_path}}/assets/img/extend/rebranded-ui-3.png)

- Customized self sign up page
![image]({{base_path}}/assets/img/extend/rebranded-ui-4.png)

!!! note
    One advantage of this approach is that WUM updates will not affect your UI changes and you need not worry about manually adding your changes.

gha_language: CSS


text:
IrcMe
===

IrcMe is a node.js IRC bot building library with a flexible plugin system.

Installation
----

Either clone the repository into your project or use [npm](http://npmjs.org/) to install:

	npm install irc_me

From there, let's get our bot running:

	var IrcMe = require("irc_me");
	options = {
		host: "your.irc.com",
		port: "6667"
	};
	var bot = new IrcMe(options);
	bot.connect();

Options
----

Options available to pass to IrcMe:

* host
* port
* nickname
* user
* realname

Plugins!
----

Connecting to a network isn't all that useful if it doesn't respond to anything.  This
is where the plugin system comes in.  The addPlugin method takes a class with two methods:

* [bool] listener(message) - This method checks the message to determine if the callback should be run
* callback(message) - This is the callback executed when listener returns true

For example:
	Botsnack = {
		listen: function(message) {
			if(message.message.match(/^@botsnack/)) {
				return true;
			} else {
				return false;
			}
		},
		callback: function(message) {
			this.say(message.target, "Thank You! :)")
		}
	}

IrcMe does not care how the listener determines if it triggers, it just needs to return true/false.
To register your plugin, call the addPlugin method:

	bot.addPlugin(Botsnack);

license: Unlicense


text:
# Upgrading

Below you'll find special instructions to consider when upgrading to a new version of ecAudit.
Check out the [change log](CHANGES.md) for a full list of new features and fixes.

## To version 3.0.x

Administrators should be aware of the following changes when upgrading to version 3.0.0 or later.
ecAudit can be upgraded to 3.0.x from version 2.x.x as long as these and any intermediate upgrade instructions (described below) are followed.
ecAudit 0.x.x or 1.x.x must be upgraded to 2.x.x before upgrading to 3.x.x.

The command to drop legacy audit whitelist table is removed in 3.0.0, if ecAudit was updated from 0.x.x or 1.x.x to 2.x.x
the legacy table must be dropped before upgrading to 3.x.x.

## To version 2.5.x

Administrators should be aware of the following changes when upgrading to version 2.5.0 or later.
ecAudit can be upgraded to 2.5.x from any previous major version as long as these and any intermediate upgrade instructions (described below) are followed.

As of version 2.5.0 the ```AuditPasswordAuthenticator``` is deprecated and should no longer be configured as the ```authenticator``` in ```cassandra.yaml```.
Users should instead use the ```AuditAuthenticator``` which can delegate authentication operations to custom ```IAuthenticator``` implementation.
By default the new ```AuditAuthenticator``` will behave exactly like the ```AuditPasswordAuthenticator```.

## To version 2.1.x

Administrators should be aware of the following changes when upgrading from version 0.x.x, 1.x.x or 2.0.x to 2.1.0 or later.
ecAudit can be upgraded to 2.1.x from any previous major version as long as these and any intermediate upgrade instructions (described below) are followed.

As of version 2.1.0 ecAudit will read and use the configuration in the audit.yaml file stored in the Cassandra configuration directory.
This directory is typically ```/etc/cassandra/conf/``` but may be different depending on your deployment.

The path can be overridden with the ```com.ericsson.bss.cassandra.ecaudit.config``` Java property.
In previous versions of ecAudit there was a typo which caused ecAudit to evaluate the `com.ericsson.bss.cassandra.eaudit.config` Java property instead.
Users who used this previously undocumented property should fix typo in their config when upgrading to 2.1.0 or later.

## To version 2.0.x

Administrators should be aware of the following changes when upgrading from version 0.x.x or 1.x.x to 2.0.0 or later.
ecAudit can be upgraded to 2.x.x from any previous major version as long as these and any intermediate upgrade instructions (described below) are followed.

As of version 2.0.0 ecAudit support whitelisting of specific operations on a resource.
For example, it is possible to whitelisted a user for `SELECT` operations on a table, without whitelisting other operations such as the `MODIFY` operations on the same table.
Example:

```SQL
cassandra@cqlsh> ALTER ROLE bob WITH OPTIONS = { 'grant_audit_whitelist_for_select' : 'data/design/decisions' };
```

As of this version ecAudit will also support whitelist options with upper case letters and space characters instead of underscore.
So, the previous example could just as well have been expressed as:

```SQL
cassandra@cqlsh> ALTER ROLE bob WITH OPTIONS = { 'GRANT AUDIT WHITELIST FOR SELECT' : 'data/design/decisions' };
```

For a complete guide on new whitelisting options, refer to the [whitelist](doc/role_whitelist_management.md) guide.

The following non-backwards compatible changes have been made:
* It is no longer possible to configure whitelists in the `CREATE ROLE` statement - whitelists can only be configured with the `ALTER ROLE` statement
* It is no longer possible to configure whitelists for several resources in one `ALTER ROLE` statement - to whitelist several resources, issue several statements
* When using the `LIST ROLES` statement, the whitelist options are presented in a different format compared to previous versions of ecAudit
* Whitelist representation on disk have been modified - manual steps are required to upgrade properly as described below

### Instructions
Representation on disk for role based whitelists have been changed in order to support operation specific whitelists.
The new version of ecAudit can co-exist with older versions of ecAudit.
The new version of ecAudit can be applied on one node at a time.
Cassandra has to be restarted on a node for it to pick up the new version of ecAudit.
On startup, ecAudit will convert existing whitelists to the new representation.
Users should avoid to modify whitelists while there are mixed versions of ecAudit in the Cassandra cluster.

__NOTE__: Once all instances of ecAudit have been upgraded it is necessary to clean up the legacy whitelist representation for correct operation.
As a user with super-user privileges in Cassandra,
issue the following statement on one node in the cluster __after__ upgrading __all__ nodes to ecAudit 2.0.0 or later.

The super-user should perform the `ALTER ROLE` statement on itself. In this example the `cassandra` role is used.

```SQL
cassandra@cqlsh> ALTER ROLE cassandra WITH OPTIONS = { 'drop_legacy_audit_whitelist_table' : 'now' };
```

## To version 1.x.x

Administrators should be aware of the following changes when upgrading from version 0.x.x to 1.0.0 or later.
ecAudit can be upgrade to 1.x.x from any 0.x.x version as long as the upgrade instructions below are followed.

ecAudit now provides a custom authorizer plug-in in.
This is necessary in order to resolve issue #31,
allowing a role to whitelist applicable to a grantee as long as the role has `AUTHORIZE` permission on the resource.

### Instructions

As ecAudit is upgraded, make sure to configure the `authorizer` property in the `cassandra.yaml` according to the instructions in the [setup guide](doc/setup.md).

repository: Ericsson/ecaudit

gha_language: Java

repo_name: Ericsson/ecaudit


text:
# Pulsar Nulling

A mixture model for analyzing nulling in pulsars, improved on [Kaplan+2018](https://github.com/dlakaplan/nulling-pulsars). In addition to the standard Gaussian mixture implemented by [Kaplan+2018](https://github.com/dlakaplan/nulling-pulsars), this extends the analysis to the cases where the distribution is more accurately described by an [exponentially modified Gaussian](https://en.wikipedia.org/wiki/Exponentially_modified_Gaussian_distribution). This also allows to study the correlations in nulling, particularly looking for periodicities in the nulling patterns. Can also be used to study basic drifitng phenonmenon.

## It can be installed via pip:

```
git clone git@github.com:AkashA98/pulsar_nulling.git
cd pulsar_nulling/
pip install .
```
#### Or in the standard way as
```
python ./setup.py install
```

## Example of the code usage:

If the user has the ON and OFF window intensities as arrays

```
from nulling.get_nf import nulls
nf = nulls(on, off, ncomp=2, model='exp_tail', nwalkers=32, burnin=200, nsteps=5000)
nf.run_mcmc(corr=True)
```
If the user wants to take into account the finite correlation length of the chain in order to get independent samples, then they can set the ```corr``` flag to True. All the results are available as class attributes. For example, the best fit values can be obtained by ```nf.fit_val``` and the errors can be obtained by ```nf.fit_err```. The ordering or parameters will always be
##### [means, standard deviations, tau(optional), weights]

For example, in the case of a 2 component Gaussian model, they will be [mu1, mu2, std1, std2, nf] (Remember all the weights are not independent) and in the case of a 2 component exponentially modified gaussian, they will be [mu1, mu2, std1, std2, tau, nf]

The posteriors for the model parameters and the fit for the histograms can be plotted using

```
nf.plot_fit()
```

Comaprison of different models can be done using the Akaike information criterion [AIC](https://en.wikipedia.org/wiki/Akaike_information_criterion) and Bayesian information criterion [BIC](https://en.wikipedia.org/wiki/Bayesian_information_criterion) and can be obained by calling

```
nf.AIC()
nf.BIC()
```

and accessed as ```nf.aic_val``` and ```nf.bic_val```.

Once the nulling results are available, one can look for correlations in nulling. This depends on the null probabilities, the probability that a single pulse is null.

```
from nulling.correlations import *
NP = get_nf_prob(on, model="exp_tail", ndim=2, fit_val=nf.fit_val)
freq, power, lim, fwhm = get_nfprob_fft(NP)
```

where ```freq``` is the fourier frequencies, ```power``` is the stacked power from stacks of 256 single pulses (to mitigate ISM effects) and the ```lim``` is the analytical limit assuming FAR=0.001 under the null hypothesis of pure noise.

One can also look at the null and emission length histograms
```
null_len_dist, em_len_dist, null_len_tau, em_len_tau = get_null_em_dist(NP)
```
which gives the null and emission length distributions and the decay constant assuming an exponential fit.

Finally, one can look for drifitng patterns using the 2D pulse stack. If ```sps``` is the 2D array of the single pulses

```
freq, 2d_power = get_sps_fft(sps, plot=True)
```

branch_name: refs/heads/main


text:
# axx

Encrypt / decrypt files from the command line.

![](https://cdn-images-1.medium.com/max/1600/1*xaPn6yEq6H_3TNc7ZZkDew.png)

```
$ axx
OVERVIEW: Encrypt/decrypt files from the command line

USAGE: axx <command> <options> <files>

SUBCOMMANDS:
  d                       Decrypt one or more files
  e                       Encrypt one or more files
  k                       Generate new encryption key
```

## Key File Generation

```
$ axx k > ~/.mykey.pem
```

⚠ Keys must be kept safe and secure. Without the key, it would be impossible to recover an encrypted file.

### File Encryption

```
$ axx e -i ~/.mykey.pem secretstuff.txt
```

### File Decryption

```
$ axx d -i ~/.mykey.pem secretstuff.txt.enc
```

## Installation

### With Homebrew
```
$ brew install eneko/tap/axx
```

### From source
```
$ git clone https://github.com/eneko/Axx.git && cd Axx
$ make install
```


text:
# Notable CLI
This is a command line interface (CLI) for [Notable](http://zurb.com/notable), a design feedback application by [ZURB](http://zurb.com). Right now it supports uploading sites to Notable Code. **This currently only supports Mac OSX.** Other systems are supported by [compiling from source](#compile-from-source).

## Install
Use [Homebrew](http://brew.sh/) to install the Notable CLI.

```
brew tap zurb/tap
brew install notable
```

You are now ready to go!

## Authenticate
Before you can use the CLI, you must authenticate it with your [Notable](http://zurb.com/notable) account.

```
notable login
```

Logout by running:

```
notable logout
```

Once authenticated, you can run any of the following commands.

## Upgrade
To get the latest changes to the Notable CLI, run the following command:

```
brew up && brew upgrade notable
```

## Upload to Notable Code
Capture any URL, including local URLs, by running the `code` command followed by the address of the site to capture. For instance, if you have a local application running at `localhost:3000` then run the following command to upload it to [Notable Code](http://zurb.com/notable/features/code).

```
notable code localhost:3000
```

Your browser will automatically open, once captured, to the Notable Code site that you just uploaded.

Capture live sites the same way:

```
notable code http://www.nytimes.com/
```

Or use the shorcut:

```
notable c http://zurb.com/notable
```

## Upload to Notable Notebooks
You can create a Notebook from a directory of images by running the following command from _inside_ the directory you want to upload.

```
notable notebook create
```

This command will upload all images in the current directory and open the Notebook in your browser when done.

Or use the shortcut:

```
notable n create
```

## Compile from source
The provided Homebrew binary is meant for Mac OSX, but if you would like to run the CLI on Windows or Linux based systems, compiling from source is your answer.

The Notable CLI is built in go, so install [go](https://golang.org) then clone down this repository into your working directory.

```
go get github.com/zurb/notable-cli
```

Then build it:

```
go build -o notable
```

That's it! You now have an executable binary for your OS.

repository: zurb/notable-cli

gha_language: Go

repo_name: zurb/notable-cli


text:
# common-denominators

![Node CI](https://github.com/staghouse/common-denominators/workflows/Node%20CI/badge.svg)
![codecov](https://codecov.io/gh/staghouse/common-denominators/branch/master/graph/badge.svg)
![npm version](https://img.shields.io/npm/v/common-denominators)

A JS function that takes any number of arguments and returns an array of all the common denominators of any numbers supplied

## The Challenge

Write your own `commonDenominators` function inside of `src/index.js`. Run the `validate` command to test and benchmark your code against the stable. If all tests pass and the benchmark improves over the stable then PR!

## Install local dev dependencies

```
npm install
```

## Usage

```js
const commonDenominators = require('common-denominators');

commonDenominators(6, 12, 24, 30); // -> [1, 2, 3, 6]
```

## Development

Minify, test and benchmark

```terminal
npm run validate
```

Run only unit tests

```terminal
// test all files once
npm run test

// test on source
npm run test:source

// watch and test on source
npm run test:watch
```

Run only benchmarks

```terminal
npm run benchmark
```

Build distribution package. Overwrites the current package export. *(This should be the fastest passing version)*

```terminal
npm run build:dist
```

repository: staghouse/common-denominators

gha_language: JavaScript

gha_license_id: MIT

repo_name: staghouse/common-denominators


text:
# Contributing to GrillinFools

## Using the issue tracker

The issue tracker is the preferred channel for [bug reports](#bugs) and
[features requests](#features).

## Bug reports

Try to be as detailed as possible and include the page on which the issue occured as well as what changes you may have done

## Feature requests

Feature requests are welcome. Make sure they are concise and singular - one feature per request.


text:
---
layout: "rollbar"
page_title: "Rollbar: rollbar_pagerduty_notification_rule"
sidebar_current: "docs-rollbar-resource-pagerduty-notification-rule"
description: |-
  Provides a resource to create and partially manage Rollbar PagerDuty notification rules.
---

# rollbar\_pagerduty\_notification\_rule

This resource is used to manage Rollbar's PagerDuty notification rules. You must supply a `project_access_token` with write
permissions in other to manage this resource.

For more information on the supported values when constructing a rule, please visit [this page](https://docs.rollbar.com/reference#setup-pagerduty-notification-rules).
(Yes, you'll have to read an OpenAPI spec.)

~> NOTE: Due to API limitations, it is not possible to selectively `GET`, `DELETE` or `CREATE` a single notification rule.
Whatever rule(s) you define in your terraform configuration **will be the only rules** present in your account
after a `terraform apply`. This is especially important to understand if you have pre-existing rules in your account
prior to terraform managing this resource or rules created outside of terraform. In other words, this provider/terraform
will overwrite any remotely defined rules not in your configuration files.

## Example Usage

```hcl
# Create a new Rollbar PagerDuty notification rule
resource "rollbar_pagerduty_notification_rule" "foobar" {
	rule {
		trigger = "new_item"
		filter {
			type = "level"
			operation = "gte"
			value = "critical"
		}
		filter {
			type = "title"
			operation = "within"
			value = "some_title"
		}
	}

	rule {
		trigger = "new_item"
		filter {
			type = "environment"
			operation = "eq"
			value = "production"
		}
		config = {
			service_key = "aG59dD4FtWRfGMNJ3mLcZTK3CC4Qhgas" // this is not a real `service_key`
		}
	}
}
```

## Argument Reference

The following arguments are supported:

* `rule` - (Required) A PagerDuty notification rule

    * `trigger` - (Required) `<string>` The only valid option is `new_item` for now.

    * `filter` - (Required)

        * `type` - (Required) `<string>` The type of rule filter.
        Valid options are: `environment`, `level`, `title`, `filename`,`context`, `method`, `framework`, `path`.

        * `operation` - (Required) `<string>`

        * `value` - (Optional) `<string>` This attribute is **required** for all filter types except for when constructing
        a 'path_filter_with_exists' filter. See the API documentation (OpenAPI Spec) for more information. The attribute
        itself is marked as 'Optional' to support a 'path_filter_with_exists' filter.

        * `path` - (Optional) `<string>` This attribute is used only for filter type `path`.

    * `config` - (Optional) Any additional rule configurations

        * `service_key` - (Required) `string` Use this service API key instead of the default PagerDuty Service API key.

### Filter Explanations

As of Feb 11th, 2020, the Rollbar Rest API documentation does not present the available options to the `rule.filter`
attribute block in an easily readable manner. Therefore, this section will provide a summary of the available
options for `rule.filter`:

1. For `filter.type` type `environment`:
    * Valid `filter.operation` option(s): `eq`, `neq`
    * Valid `filter.value` option(s): any freeform `string`*

1. For `filter.type` type `level`:
       * Valid `filter.operation` option(s): `eq`, `gte`
       * Valid `filter.value` option(s): `debug`, `info`, `warning`, `error`, `critical` (case sensitive!)

1. For `filter.type` type `title`:
      * Valid `filter.operation` option(s): `within`, `nwithin`, `regex`, `nregex`
      * Valid `filter.value` option(s): any freeform `string`*

1. For `filter.type` type `filename`:
    * Valid `filter.operation` option(s): `within`, `nwithin`, `regex`, `nregex`
    * Valid `filter.value` option(s): any freeform `string`*

1. For `filter.type` type `context`:
    * Valid `filter.operation` option(s): `startswith`, `eq`, `neq`
    * Valid `filter.value` option(s): any freeform `string`*

1. For `filter.type` type `method`:
    * Valid `filter.operation` option(s): `within`, `nwithin`, `regex`, `nregex`
    * Valid `filter.value` option(s): any freeform `string`*

1. For `filter.type` type `framework`:
    * Valid `filter.operation` option(s): `eq`
    * Valid `filter.value` option(s): any freeform `string`*

For the `filter.type` type `path`, there are two possible setups:

* If you define `filter.value` & `filter.operation` in your terraform configuration,
    * Valid `filter.operation` option(s): `eq`, `gte`, `lte`, `within`, `nwithin`, `neq`, `regex`, `nregex`, `startswith`
    * Valid `filter.value` option(s): any freeform `string`*
    * Valid `filter.path` option(s): any freeform `string`*

* If you only define `filter.operation` in your terraform configuration _(aka 'path_filter_with_exists)_,
    * Valid `filter.operation` option(s): `eq`, `gte`, `lte`, `within`, `nwithin`, `neq`, `regex`, `nregex`, `startswith`,
    `exists`, `nexists`
    * Valid `filter.value` option(s): any freeform `string`* & is Optional.
    * Valid `filter.path` option(s): any freeform `string`*

**Note:** Any `filter.value` with an asterisk may not be fully accurate. Please open an issue on the GitHub repository
if you encounter any problems.

## Attributes Reference

N/A

## Import

Due to API limitations, it is not possible to import an existing PagerDuty notification rule(s).

repository: aceysmith/terraform-provider-rollbar

extension: markdown

repo_name: aceysmith/terraform-provider-rollbar


text:
---
layout: post
title: Mayall Telescope Cartoon
image: /cartoons/images/Mayall_Telescope_Only_Telescope.jpg
share-img: http://www.jessiemuir.com/cartoons/images/Mayall_Telescope_Only_Telescope.jpg
social-share: true
use-site-title: true
---

This is a cartoon of the Mayall 4-meter telescope at Kitt Peak National Observatory, which is home to the Dark Energy Spectroscopic Instrument [(DESI)](https://www.desi.lbl.gov/). It will be used for the  [DESI High School](https://github.com/michaelJwilson/DESI-HighSchool) outreach project.

![alt="Cartoon of the Mayall 4-meter telecope at Kitt Peak National Observatory."](/cartoons/images/Mayall_Telescope_Only_Telescope.jpg)

gha_language: HTML

gha_license_id: NOASSERTION


text:
# Ruvy

Experimental FFI bindings for Libuv

## Goal

Create a ruby version of node.js :D

## Why FFI Bindings?

[Libuv](https://github.com/joyent/libuv) is a project that move very very fast and write a C wrapper
will require a big amount of time. So instead I did a custom version [this great project](https://github.com/neelance/ffi-gen)
[here](https://github.com/daddye/ffi-gen) in order to generate easily an updated wrapper around
[ruby ffi](https://github.com/ffi/ffi) to provide a direct interface to [Libuv](https://github.com/joyent/libuv).
Future more I'll provide an higher level API in [node.js](http://nodejs.org).

## Author

DAddYE, you can follow me on twitter [@daddye](http://twitter.com/daddye) or take a look at my site [daddye.it](http://www.daddye.it)

## Copyright

Copyright (C) 2011 Davide D'Agostino - [@daddye](http://twitter.com/daddye)

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

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

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

repository: dariocravero/ruvy

repo_name: dariocravero/ruvy


text:
### [CVE-2017-18347](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2017-18347)
![](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

Incorrect access control in RDP Level 1 on STMicroelectronics STM32F0 series devices allows physically present attackers to extract the device's protected firmware via a special sequence of Serial Wire Debug (SWD) commands because there is a race condition between full initialization of the SWD interface and the setup of flash protection.

### POC

#### Reference
- https://www.aisec.fraunhofer.de/en/FirmwareProtection.html

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

repository: trickest/cve

repo_name: trickest/cve


text:
---
title: Building for release
description: Learn about how to build the Dolittle Edge Agent for release
keywords: Edge
author: einari
weight: 3
---
This project uses [Gox](https://github.com/mitchellh/gox) a simplified way
to do cross compilation.

Install it as follows:

```shell
go get github.com/mitchellh/gox
```

You can then run the `build.sh` file inside the `Source` folder.
It will output the binary in the `output` folder within `Source` folder.
The output is targetting Linux.

repository: pavsaund/Agent

repo_name: pavsaund/Agent


text:
# How to Contribute

This project welcomes contributions from the community. Please follow this guide
when logging issues or making code changes.

Make sure you have Elixir 1.6 or greater installed. Copy and paste the following
commands in your projects directory.

    git clone https://github.com/mpiercy827/downstream.git
    cd downstream
    mix deps.get

## Contributing Instructions

1. Fork repo.
2. Create your feature branch (`git checkout -b my-new-feature`).
3. Commit your changes (`git commit -am 'Add some feature'`).
4. Push to the branch (`git push origin my-new-feature`).
5. Make sure the tests pass (`mix coveralls.html`).
6. Open up `cover/excoveralls.html` in your browser and add tests if required to meet the minimum coverage threshold.
7. Create new Pull Request.

repository: kianmeng/downstream

repo_name: kianmeng/downstream


text:
# Constraint-based graph network simulator

```
@inproceedings{cgns_icml22,
author = {Rubanova, Yulia and Sanchez-Gonzalez, Alvaro and Pfaff, Tobias and Battaglia, Peter},
title = {Constraint-based graph network simulator},
booktitle = {Proceedings of the 39th International Conference on Machine Learning (ICML)},
pages = {18844--18870},
year = {2022}
}
```

links
 - [pmlr](https://proceedings.mlr.press/v162/rubanova22a.html)
- [icml](https://icml.cc/Conferences/2022/Schedule?showEvent=17852)
- [arXiv](https://arxiv.org/abs/2112.09161)

gha_language: Jupyter Notebook


text:
# Spring Cloud Alibaba Containerized Deployment Best Practices | Docker-Compose Edition

## Preparation

If you have not installed Docker or Docker-Compose, please follow the official documentation to build the environment

> Note: When using Docker-Compose to experience the demo, please make sure that the local machine memory resource is >= 24G!

- Docker：https://docs.docker.com/desktop/install/linux-install/
- Docker-Compose：https://docs.docker.com/compose/install/

### Hosts configuration

To ensure that the code can start properly, please configure the local host mapping first, add the following mapping to the configuration file.

```shell
# for integrated-example
<IP_ADDRESS> integrated-mysql
<IP_ADDRESS> nacos-server
<IP_ADDRESS> seata-server
<IP_ADDRESS> rocketmq
<IP_ADDRESS> gateway-service
<IP_ADDRESS> integrated-frontend
```

### Preparing jar packages

Go to the `spring-cloud-alibaba-examples` directory and run the `mvn package` command to compile the project and generate the jar package, so as to prepare for the subsequent construction of the docker service image.

## Quickly start

### Component start

Enter `spring-cloud-alibaba-examples/integration-example` directory, run the following command in the terminal to quickly deploy the components required to run example: `docker-compose -f ./docker-compose/docker-compose-env.yml up -d`.

### Add configuration

After docker-compose-env.yml is run successfully, add the Nacos configuration:

- Enter `spring-cloud-alibaba-examples/integration-example` directory;
- Execute the `config-init/scripts/nacos-config-quick.sh` script file in the terminal.

The one-click import of all micro-service configurations is complete.

> Note: windows operating systems can use `git bash` to execute shell script files to complete the configuration import.

### Service start

Enter `spring-cloud-alibaba-examples/integration-example` directory, Run the following command in the terminal to quickly deploy the services required for running example: `docker-compose -f ./docker-compose/docker-compose-service.yml up -d`.

## Stop all containers

### Stops the service container

Enter `spring-cloud-alibaba-examples/integration-examplee` directory, Run the following command in the terminal to `docker-compose -f ./docker-compose/docker-compose-service.yml down` to stop the running example service container.

### Stops the component container

Enter `spring-cloud-alibaba-examples/integration-example` directory, Run the following command in the terminal to `docker-compose -f ./docker-compose/docker-compose-env.yml down` to stop the running example component container.

> When the container starts, you can observe the startup process of the container through `docker-compose- f docker-compose-*.yml up`!

## Experience Demo

After the preparation work is done, you can run the demo, mainly according to different usage scenarios, you can experience the user order (distributed transaction capability) and simulate the high traffic point (meltdown and limit the flow as well as the ability to cut the peak and fill the valley) respectively.

First, you need to start the `integrated-frontend` and `integrated-gateway` projects separately.

- The gateway module is the gateway for the entire best practice example.
- frontend is the simple front-end page for the best practice.

### Distributed Transaction Capabilities

#### Scenario Description

For the distributed transaction capability, we provide the scenario **where a user places an order for goods** and after placing the order.

- First request the inventory module and deduct the inventory
- Deduct the account balance
- Generate order information to return a response

##### Start test

Start `integrated-storage`,`integrated-account`,`integrated-order` microservices respectively.

Visit `http://integrated-frontend:8080/order` to experience the corresponding scenario.

By clicking the order button directly to submit the form, we simulate the client sending a request to the gateway to create an order.

- The user's userId is admin
- The item number of the user's order is 1
- The number of items purchased in this order is 1

![](https://my-img-1.oss-cn-hangzhou.aliyuncs.com/image-20221016155416524.png)

In this demo example, the unit price of each item is 2 for demonstration purposes.

And in the previous preparation, **initialize business database table** we created a new user userId = admin with a balance of $3, and a new item numbered 1 with 100 units in stock.

So by doing the above, we will create an order, deduct the number of items in stock corresponding to item number 1 (100-1=99), and deduct the balance of the admin user (3-2=1).

![](https://my-img-1.oss-cn-hangzhou.aliyuncs.com/image-20221016155429801.png)

If the same interface is requested again, again the inventory is deducted first (99-1=98), but an exception is thrown because the admin user's balance is insufficient and is caught by Seata, which performs a two-stage commit of the distributed transaction and rolls back the transaction.

![](https://my-img-1.oss-cn-hangzhou.aliyuncs.com/image-20221016155436112.png)

You can see that the database still has 99 records in stock because of the rollback.

### Fused flow limiting, peak shaving capability

#### Scenario Description

For service fusion limiting and peak and valley cutting in the context of high traffic, we provide a scenario **where users make likes for products**. In this scenario, we provide two ways to deal with high traffic.

- Sentinel binds specified gateway routes on the gateway side for fusion degradation of services.
- RocketMQ performs traffic clipping, where the producer sends messages to RocketMQ under high traffic requests, while the consumer pulls and consumes through a configurable consumption rate, reducing the pressure of high traffic direct requests to the database to increase the number of likes requests.

#### Startup test

Start the `integrated-praise-provider` and `integrated-praise-consumer` modules separately.

- Sentinel service meltdown degradation

Visit `http://integrated-frontend:8080/sentinel` to experience the corresponding scenario.

![](https://my-img-1.oss-cn-hangzhou.aliyuncs.com/image-20221016155501290.png)

The Gateway routing point service has a flow limit rule of 5, while 10 concurrent requests are simulated on the front end through asynchronous processing.

Therefore, we can see that Sentinel performs a service fusion on the Gateway side to return the fallback to the client for the extra traffic, while the number of likes in the database is updated (+5).

![](https://my-img-1.oss-cn-hangzhou.aliyuncs.com/image-20220914155755103.png)

- RocketMQ is performing peak and valley reduction

Visit `http://integrated-frontend:8080/rocketmq` to experience the corresponding scenario.

Since we previously configured the consumption rate and interval of the `integrated-praise-consumer` consumer module in Nacos, we simulate 1000 requests for likes at the click of a button, and the `integrated-praise-provider`
will deliver 1000 requests to the Broker, and the consumer module will consume them according to the configured consumption rate, and update the database with the product data of the likes, simulating the characteristics of RocketMQ to cut the peaks and fill the valleys under high traffic.

You can see that the number of likes in the database is being dynamically updated.

![](https://my-img-1.oss-cn-hangzhou.aliyuncs.com/image-20221016173604059.png)

## Other

This example **is just a selection of typical features for each component to serve the application scenario**.

If you are interested or want to go deeper, you are welcome to study the individual example documentation for each component.

- Nacos examples
    - [Nacos config example](../../../nacos-example/nacos-config-example/readme.md)
    - [Nacos discovery example](../../../nacos-example/nacos-discovery-example/readme.md)
- [Sentinel core example](../../../sentinel-example/sentinel-core-example/readme.md)
- [Seata example](../../../seata-example/readme.md)
- [RocketMQ example](../../rocketmq-example/readme.md)


text:
Dockerized MyTardis
===================

This is a dockerized build of the 3.7 branch of the Mytardis Data Curation system: http://mytardis.org

Creates an assembly of docker containers that provide the mytardis webportal, persistent tardis store and mysql/postgres db,  rabbitmq message broker, two celery workers, and celery monitoring interface, ELK logging,  all working on a single host.

The build has three types of configurations
- **postgres**: Uses PostgreSQL db; users are managed via local Django user management only
- **mysql**: Uses MySQL db; users are managed via local Django user management only
- **cas**: Uses MySQL db, users are managed via local Django user management and Central Authentication Service (CAS)

Usage
-----

1. Install latest version of docker-engine and docker-compose (http://docs.docker.com/compose)

2. Clone `docker-mytardis` repository
```
    git clone https://github.com/ianedwardthomas/docker-mytardis.git
```

3. Configure the mytardis build. The build can be configured as *postgres*, *mysql*, or *cas*. The following configures the build to use PostgreSQL.
```
    - cd docker-mytardis
    - ./init postgres
```

4. Copy the default environment variables:
```
    cp env .env
```
  and change passwords in ```.env```.

5. Start the system in either of the following ways:
   - To start the system from existing images of MyTardis and related components  using self-signed certificate (Recommended):
```
    docker-compose pull
    docker-compose run makecerts
    docker-compose up -d
```

  - To start the system after building new images of MyTardis and related components using self-signed certificate (only if you intend to make changes to the `docker-mytardis` codebase):

```
    docker-compose build
    docker-compose run makecerts
    docker-compose up -d
```

  After a while, the location http://<IP_ADDRESS> will point at the mytardis portal. To watch the celery workers go to: http://<IP_ADDRESS>:5555.

6. To create a root user:

```
  docker exec -ti dockermytardis_app_1 python /opt/mytardis/webapp/mytardis.py createsuperuser --user=root
```

The ```nginx_conf``` directory has information for setup of the kibana log visualiser

This project is working reasonably well as demo, but IS NOT FOR PRODUCTION USE

Acknowledgements
----------------

Grischa for the initial inspiration at https://github.com/grischa/mytardis-docker

repository: ianedwardthomas/docker-mytardis

gha_language: Shell

repo_name: ianedwardthomas/docker-mytardis


text:
---
layout: post
categories: [useful, ibm]
tags: ibm
image: https://acclaim-production-app.s3.amazonaws.com/images/60f2e1e1-1b74-4dc0-a24b-cd08b460c12d/Applied%2BData%2BScience%2BCapstone.png
---

> IBM and Coursera launched an online Data Science Professional Certificate to address the shortage of skills in data-related professions. This certificate is designed for those interested in a career in Data Science or Machine Learning, and equips them to become job-ready through hands-on, practical learning.

> taken from official blog of [IBM](https://cognitiveclass.ai/blog/data-science-professional-certificate/).

#### In this post we look at:
- why this certificate is being created (the demand),
- what is being offered,
- how it differs from other offerings,
- who it is for,
- the duration and cost,
- what outcomes you should expect,
- and your next steps.

### Why this Professional Certificate
Data is collected in every aspect of our existence. The true transformative impact of data is realizable only when we can mine and act upon the insights contained within the data. Thus it is no surprise to see phrases such as “data is the new oil” (Economist).

We see organizations in most spaces seeding data-related initiatives. Companies that leverage and act upon the gems of information contained within data will get ahead of the competition – or even transform their industries. The transformative aspect of data is also applicable to the not-for-profit sector, for the betterment of society and improving our existence.

A variety of data related professions are relevant: **Data Scientist**, _Data Engineer, Data Analyst, Database Developer,_ Business Intelligence (BI) Analyst, etc., and the most prominent of those is Data Scientist. It has been called “the best job of the 21st century” by the Harvard Business Review, and **Glassdoor** calls it the “best job in America”.

Job listings and salary profiles for this profession clearly reflect this. When we talk to our clients we see a common thread: they can’t find enough qualified people to staff their data projects. This has created a tremendous opportunity for data professionals, especially Data.

In a recent report, IBM projected that “by _2020_ the number of positions for data and analytics talent in the United States will increase by **364,000 openings, to 2,720,000**”. The global demand is even higher.

Even though Data Science is “hot and sexy” and might enable you to get a great job today, the question is will it continue to be in demand and important going forward?

I certainly believe so, at least for another decade or more. Data is being created and collected at a rapid pace, and the number of organizations leveraging data is also expected to increase significantly.

“IBM’s Data Science Professional Certificate on _Coursera_ fulfills a massive need for more data science talent in the US and globally,” said Leah Belsky, Vice President of Enterprise at Coursera. “Coursera offers online courses on everything from computer science to literature, but over a quarter of all enrollments from our 7 million users in the US are in data science alone. We expect IBM’s certificate will become a valuable credential for people wanting to start a career in data science.”

### What we offer
It is with this in mind IBM developed the Data Science Professional Certificate. It consists of 9 courses that are intended to arm you with latest job-ready skills and techniques in Data Science.

The courses cover variety of data science topics including: open source tools and libraries, methodologies, Python, databases and SQL, data visualization, data analysis, and machine learning. You will practice hands-on in the IBM Cloud (at no additional cost) using real data science tools and real-world data sets.

The courses in the Data Science Professional Certificate include:

What is Data Science
Tools for Data Science
Data Science Methodology
Python for Data Science
Databases and SQL for Data Science
Data Visualization with Python
Data Analysis with Python
Machine Learning with Python
Applied Data Science Capstone

### How it is different
This professional certificate has a strong emphasis on applied learning. Except for the first course, all other courses include a series of hands-on labs and are performed in the IBM Cloud (without any cost to you).

Throughout this Professional Certificate you are exposed to a series of tools, libraries, cloud services, datasets, algorithms, assignments and projects that will provide you with practical skills with applicability to real jobs that employers value, including:

Tools: Jupyter / JupyterLab, Zeppelin notebooks, R Studio, Watson Studio, Db2 database
Libraries: Pandas, NumPy, Matplotlib, Seaborn, Folium, ipython-sql, Scikit-learn, ScipPy, etc.
Projects: random album generator, predict housing prices, best classifier model, battle of neighborhoods

### Who this is for
Data Science is for everyone – not just those with a Master’s or Ph.D. Anyone can become a Data Scientist, whether or not you currently have computer science or programming skills. It is suitable for those entering the workforce as well as for existing professionals looking to upskill/re-skill themselves and get ahead in their careers.

In the Data Science Professional Certificate we start small, re-enforce applied learning, and build to more complex topics.

I consider a Data Scientist as someone who can find the right data, prepare it, analyze and visualize data using a variety of tools and algorithms, build data experiments and models, run these experiments, learn from them, adjust and re-iterate as needed, and eventually be able to tell the story hidden within data so it can be acted upon – either by a human or a machine.

If you are passionate about pursuing a career line that is in high demand with above average starting salaries, and if you have the drive and discipline for self-learning, this Data Science Professional Certificate is for you.

“Now is a great time to enter the Data Science profession and IBM is committed to help address the skills gap and promote data literacy” says Leon Katsnelson, CTO and Director, IBM Developer Skills Network. “Coursera, with over 33 million registered learners, is a great platform for us to partner with and help with our mission to democratize data skills and build a pipeline of data literate professionals.”

### Cost and Duration
The courses in this certificate are offered online for self-learning and available for “audit” at no cost. “Auditing” a course gives you the ability to access all lectures, readings, labs, and non-graded assignments at no charge. If you want to learn and develop skills you can audit all the courses for free.

The graded quizzes, assignments, and verified certificates are only available with a low-cost monthly subscription (just $39 USD per month for a limited time). So if you require a verified certificate to showcase your achievement with prospective employers and others, you will need to purchase the subscription. Enterprises looking to skill their employees in Data Science can access the Coursera for Business offering. Financial aid is also available for those who qualify.

The certificate requires completion of 9 courses. Each course typically contains 3-6 modules with an average effort of 2 to 4 hours per module. If learning part-time (e.g. 1 module per week), it would take 6 to 12 months to complete the entire certificate. If learning full-time (e.g. 1 module per day) the certificate can be completed in 2 to 3 months.

### Outcomes
Upon completing the courses in this Professional Certificate you will have done several hands-on assignments and built a portfolio of Data Science projects to provide you with the confidence to plunge into an exciting profession in Data Science.

Those pursuing a paid certificate will not only receive a course completion certificate for every course they complete but also receive an IBM open badge. Successfully completing all courses earns you the Data Science Professional Certificate as well as an IBM digital badge recognizing your proficiency in Data Science. These credentials can be shared on your social profiles such as LinkedIn, and also with employers.

IBM and Coursera are also working together to form a hiring consortium. Learners who obtain the verified Certificate will be able to opt-in to have their resumes sent to employers in the consortium.

### Next Steps
All courses in this [Data Science Professional Certificate](https://www.coursera.org/specializations/data-science-professional-certificate) are live and available. Enroll today, start developing skills employers are looking for, and kickstart your career in Data Science.

***All the Best.!!***

> You can apply for Financial-Aid to all the above courses where you can get them for free only after auditing each individual course and apply for each course separately.

Plz comment below if you need any help for applying financial-aid.

repository: StarkSources/myblog

repo_name: StarkSources/myblog


text:
```
neu version
```

```
  _   _            _             _ _             _
 | \ | | ___ _   _| |_ _ __ __ _| (_)_ __   ___ (_)___
 |  \| |/ _ \ | | | __| '__/ _` | | | '_ \ / _ \| / __|
 | |\  |  __/ |_| | |_| | | (_| | | | | | | (_) | \__ \
 |_| \_|\___|\__,_|\__|_|  \__,_|_|_|_| |_|\___// |___/
                                              |__/
--- Global ---
Neutralinojs binaries: v2.8.0
Neutralinojs client: v1.5.0
neu CLI: v6.2.0
INFO Run this command inside your project directory to get project specific Neutralinojs version.
```

react version information

```
  "dependencies": {
    "@testing-library/jest-dom": "^5.11.4",
    "@testing-library/react": "^11.1.0",
    "@testing-library/user-event": "^12.1.10",
    "@types/jest": "^26.0.15",
    "@types/node": "^12.0.0",
    "@types/react": "^17.0.0",
    "@types/react-dom": "^17.0.0",
    "react": "^17.0.2",
    "react-dom": "^17.0.2",
    "react-scripts": "4.0.3",
    "typescript": "^4.1.2",
    "web-vitals": "^1.0.1"
  },
```

### Create neu project

```
neu create demo
```

### Create React Project with name `temp`

```
npx create-react-app temp --template typescript
```
or
```
yarn create react-app temp --template typescript
```

> I will merge `demo` and `temp` folders with some files modify.

### Merge `README.md` and `.gitignore`

There are `README.md` and `.gitignore` same name in `demo` and `temp` folders. After modify files I will move `temp/*` into `demo/`. So I made change on `temp` folder.

Combine `Readme.md`

```
cat demo/README.md >> temp/README.md
```

Combine `.gitignore`

```
cat demo/.gitignore >> temp/.gitignore
```

Movie `temp/*` into `demo/` folder

```
mv temp/* demo/
# In macOS will not move .* files, So I need next command to move .gitignore
mv temp/.gitignore demo/
rm -rfd temp
```

Now, we have one folder combine neu and react. Then change directory to demo.

```
cd demo
```

### Move `resources/*` to `public/`

Neutralinojs default config url is `/resources/` folder in `neutralino.config.json`. I will not change it, so I have to change the file path of build react path to /resources.

Move files in `resources/` to `public/`, but exclude `index.html`

```
mv resources/icons public/
mv resources/js public/
mv resources/styles.css public/
```

There already has `public/index.html`, it is entry target to start the react app.

React use `public/index.html` as entry target. I just copy some lines from `demo/resources/index.html` into `demo/public/index.html`.

In this sample code I add `+` symbol as change line copy from `demo/resources/index.html`.

*demo/public/index.html* full content after modified.
```
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8" />
    <link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <meta name="theme-color" content="#000000" />
    <meta
      name="description"
      content="Web site created using create-react-app"
    />
    <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
    <!--
      manifest.json provides metadata used when your web app is installed on a
      user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
    -->
    <link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
    <!--
      Notice the use of %PUBLIC_URL% in the tags above.
      It will be replaced with the URL of the `public` folder during the build.
      Only files inside the `public` folder can be referenced from the HTML.

      Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
      work correctly both with client-side routing and a non-root public URL.
      Learn how to configure a non-root public URL by running `npm run build`.
    -->
    <title>React App</title>

+    <link rel="stylesheet" href="styles.css">

  </head>
  <body>
+    <div id="neutralinoapp">
+      <h1>NeutralinoJs</h1>
+      <div id="info"></div>
+      <br/>
+      <div>
+        <a href="#" onclick="window.myApp.openDocs();">Docs</a> ·
+        <a href="#" onclick="window.myApp.openTutorial();">Tutorial</a>
+      </div>
+    </div>
+    <!-- Neutralino.js client. This file is gitignored,
+        because `neu update` typically downloads it.
+        Avoid copy-pasting it.
+        -->
+    <script src="js/neutralino.js"></script>
+    <!-- Your app's source files -->
+    <script src="js/main.js"></script>

    <noscript>You need to enable JavaScript to run this app.</noscript>
    <div id="root"></div>
    <!--
      This HTML file is a template.
      If you open it directly in the browser, you will see an empty page.

      You can add webfonts, meta tags, or analytics to this file.
      The build step will place the bundled scripts into the <body> tag.

      To begin the development, run `npm start` or `yarn start`.
      To create a production bundle, use `npm run build` or `yarn build`.
    -->
  </body>
</html>
```

### Change react build path to `./resources`

With react-scripts >= 4.0.2, this is [officially supported](https://create-react-app.dev/docs/advanced-configuration):

Edit `package.json`, configure react build path.

```
// package.json
  "scripts": {
+    "build": "BUILD_PATH='./resources' react-scripts build",
  },
```

or adding a .env file to the root of your project:

```
# .env
BUILD_PATH='./resources'
```

Set git ignore `resources` folder if you have use git.

```
echo "/resources" >> .gitignore
```

Now you can run `npm run build` or `yarn build`. It will build react app into `./resources` folder.

---
**Important warning**

When writing a BUILD_PATH make sure that the path you write doesn't exist or you don't mind be erased. Doing `BUILD_PATH='..'` made some serious damage to progress I made on my project. (It deleted git as well.)

---

### Change Cli.clientLibrary path

Modify `./neutralino.config.json`

Change Cli clientLibrary path to `/public/js/neutralino.js`.
When your use `neu update` command, it will update or restore neutralino.js.

```
{
...
"url": "/resources/",
...
},
"modes": {
  "window": {
    ...
    "title": "demo",
    ...
    "icon": "/resources/icons/appIcon.png",
    ...
  },
  "browser": {},
  "cloud": {}
},
"cli": {
  "binaryName": "demo-neu",
  "resourcesPath": "/resources/",
  "clientLibrary": "/public/js/neutralino.js",
  "binaryVersion": "2.8.0",
  "clientVersion": "1.5.0"
}
}
```

Run neu app

```
neu run
```

> Ensure you run `yarn build` or `npm run build` before `neu run`.

If you are running on macOS, the window will close after it is displayed. There may be a problem with setTray().

Add check OS is not macOS then setTray().

*./public/js/main.js*

```
  setTray: () => {
      if(NL_MODE != "window") {
          console.log("INFO: Tray menu is only available in the window mode.");
          return;
      }
      let tray = {
          icon: "/resources/icons/trayIcon.png",
          menuItems: [
              {id: "VERSION", text: "Get version"},
              {id: "SEP", text: "-"},
              {id: "QUIT", text: "Quit"}
          ]
      };
+        if(NL_OS!='Darwin'){
          Neutralino.os.setTray(tray);
+        }
  },
```

it should be run success

### Edit `./package.json` scripts

* homepage: './' will be served relative to index.html
* modify scripts for use.

```
{
  "name": "demo-neu",
  "version": "0.1.0",
+ "homepage": "./",
  "private": true,
  "scripts": {
+    "react-start": "react-scripts start",
+    "react-build": "BUILD_PATH='./resources' react-scripts build",
+    "react-test": "react-scripts test",
+    "react-eject": "react-scripts eject",
+    "start": "yarn react-build && neu run",
+    "build": "yarn react-build && neu build"
  },
```

You can run

```
yarn react-build
neu run
```

will build react project in `./resources` folder
then run neu app

or just run `yarn start`. It will run `yarn react-build && neu run`

## References

* [Create React App - Advanced Configuration](https://create-react-app.dev/docs/advanced-configuration/)

With react-scripts >= 4.0.2, this is [officially supported](https://create-react-app.dev/docs/advanced-configuration):

>By default, Create React App will output compiled assets to a `/build` directory adjacent to `/src`. You may use this variable to specify a new path for Create React App to output assets. `BUILD_PATH` should be specified as a path relative to the root of your project.

## References

* [Use custom build output folder when using create-react-app - stackoverflow.com](https://stackoverflow.com/questions/41495658/use-custom-build-output-folder-when-using-create-react-app/62378644#62378644)


text:
# Lesson 10: Maps

1. Open the "[Maps](https://gobyexample.com/maps)" example and read through it.
2. How are maps like slices, and how are they different?

## Challenge

Make a program that does the following:

1. Creates a map from integers to booleans
2. Loops through the numbers 1 through 10 and sets the map where the key is the number and the value is whether the number is even \(HINT: use an If/Else or Switch!\)
3. Print out the map -> `map[1:false 2:true 3:false 4:true 5:false 6:true 7:false 8:true 9:false 10:true]`
4. Print out whether 4 is even using variables -> `The number 4 is even: true`

## Discuss

Share your code with your neighbor: what was different? What problems did you run into?

## Advanced Challenge

TBD

## Additional Resources

TBD

repository: paultyng/learn-to-code-with-go-workshop

repo_name: paultyng/learn-to-code-with-go-workshop


text:
# Handset Dataset

The data set describes uncommon handset devices usage by customers, for an interval of 12 months and with specific customer demographics. It can be used to analyze some devices trends over time, and the devices used by different groups of customers.


text:
# Formatting Guidelines

Following the ones used by `terraform fmt`:

> https://www.terraform.io/docs/configuration/style.html

- Indent two spaces for each nesting level.
- Inside a block, arguments go together first, then blocks (separated by a blank line each).
- Align their equal sign according to the longest key.

repository: closingcorporation/github-actions-js

repo_name: closingcorporation/github-actions-js


text:
---
title: Image
description: "Supported transformation fields for image"
position: 8
category: Transformations
version: 1
---
To transform and optimize your images and videos on delivery, you can pass the following fields to `options.transformations` in each build url method call or `options` in `Transformer.transform` call.

The list below is **image-only** transformations to pass along with other [basic transformation fields](/transformations/basic).

<alert type="info">

For more detailed information on each transformation, see [Cloudinary Image transformation documentation](https://cloudinary.com/documentation/image_transformation_reference).

</alert>

## `border`

- Type: `Border`
  - `width`: `string` | `number`
  - `color`: `string`. Default: `black`

Add border around the desired asset.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("example", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    border: {
      color: "red",
      width: 2,
    },
  },
});
```

## `opacity`

- Type: `Number`

Adjust the opacity of the desired image. Scale: 0 to 100 (%).

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("example", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    opacity: 30,
  },
});
```

## `underlay`

- Type: `String`

Create a layer below a partial-transparent image. This can be use with `position.x`, `position.y`, `gravity` to customize the position of the underlay.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("smartphone.png", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    underlay: "site",
  },
});
```

## `customFunction`

- Type: `CustomFunction`
  - `type`: `wasm` | `remote`
  - `source`: `string`

Call a custom function on Cloudinary side. See [Custom Functions](https://cloudinary.com/documentation/custom_functions) for more details.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("example", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    customFunction: {
      type: "wasm",
      source: "example.wasm",
    },
  },
});
```

## `color`

- Type: `String`

Color to use when text captions, shadow effect and colorize effect are in use.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("example", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    color: "red",
    effect: {
      name: "colorize:50",
    },
  },
});
```

## `defaultImage`

- Type: `String`

A public id (with extension) of a placeholder image to use if the target asset doesn't exist.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("non-exist", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    defaultImage: "avatar.png",
  },
});
```

## `density`

- Type: `Number`

To define the density when converting a vector file to image format.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("multi_page_pdf", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    dpi: 150,
  },
});
```

## `page`

- Type: `String`

To generate an image from a specified page or layer of multi-layer (multi-page) asset.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("multi_page_pdf", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    page: "2",
    gravity: "north",
    resize: {
      width: 80,
      height: 80,
      type: "fill",
    },
    format: "jpg",
  },
});
```

## `rawTransformation`

- Type: `String`

The entire transformation string (including chained one) to apply to the asset.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("example", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    rawTransformation: "l_my_image,o_90/w_400,c_fill",
  },
});
```

## `transformation`

- Type: `String`

A pre-defined named transformation to apply to the asset

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("example", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    transformation: "media_lib_thumb",
  },
});
```

## `position`

- Type: `Position`
  - `x`
    - Type: `number`
    - Horizontal coordinate for cropping, placing overlay and applying regional effects.
  - `y`
    - Type: `Number`
    - Vertical coordinate for cropping, placing overlay and applying regional effects.

```js
import { buildImageUrl } from 'cloudinary-build-url'

const url = buildImageUrl('face-top', {
  cloud: {
    cloudName: 'demo',
  },
  transformations: {
    position: {
      x: 130,
      y: 340
    }
    resize: {
      width: 80,
      height: 80,
      type: 'crop'
    }
  }
})
```

## `variables`

- Type: `Variable` | `Variable[]`

User-defined variables for keeping value assignment separate from the transformation definition. It can be used with [arithmetic expression](https://cloudinary.com/documentation/user_defined_variables#arithmetic_expressions) for computing complex transformation value.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("woman-sample", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    variables: {
      name: "$bcolor",
      value: "red",
    },
    border: {
      width: 5,
      color: "$bcolor",
    },
  },
});
```

<alert type="info">

For more details on use cases with variables, check out [User defined variable Examples](https://cloudinary.com/documentation/user_defined_variables#use_case_examples)

</alert>

## `zoom`

- Type: `String`
- Default: `1.0`

Use together with `resize.type: 'crop'` or `resize.type: 'thumb'` to decide how much of original image/video surronding the face to keep using face detection.

```js
import { buildImageUrl } from "cloudinary-build-url";

const url = buildImageUrl("woman-sample", {
  cloud: {
    cloudName: "demo",
  },
  transformations: {
    zoom: "0.75",
    gravity: "face",
    resize: {
      width: 50,
      height: 50,
      type: "thumb",
    },
  },
});
```

repository: chunksnbits/cloudinary-api

repo_name: chunksnbits/cloudinary-api


text:
# IAttachedWindowBehaviors interface

Implemented by windows (classes inheriting [BaseWindow](BaseWindow.md)). There is an implementor, but as it is currently implemented by BaseWindow - all windows implement it, inheriting this from their parent class. Because of that, this document actually describes the only implementation in use in current versions of BindKraftJS.

```Javascript
function IAttachedWindowBehaviors() {}
IAttachedWindowBehaviors.Interface("IAttachedWindowBehaviors");
IAttachedWindowBehaviors.RequiredTypes("BaseWindow");
IAttachedWindowBehaviors.prototype.attachBehavior = function(wb [,name]);
IAttachedWindowBehaviors.prototype.detachBehavior = function(wb);
IAttachedWindowBehaviors.prototype.attachedBehaviors = function(callback);
IAttachedWindowBehaviors.prototype.detachAllBehaviors = function(callback);
IAttachedWindowBehaviors.prototype.adviseAttachedBehaviors = function(msg);
IAttachedWindowBehaviors.prototype.attachedBehavior = function(callback_or_name);
```

## Methods

**attachBehavior**

    Attaches a behavior to the window.

>**wb** - the behavior instance (has to be created before calling the method)

>**name** - optional. A name for the behavior. Later this name can be used with the **attachedBehavior** method (see below).

**detachBehavior**

    Detach the behavior from the window.

>**wb** - the behavior's instance. In order to call this method the code that created the behavior must preserve its reference appropriately.

**attachedBeharviors**

    Returns all behaviors or only those seleced by the callback

>**callback** - An optional selection callback, see the `callback` in the bottom of the list.

**detachAllBehaviors**

    Detaches all the behaviors from the window or only those selected by the callback.

>**callback** - see at the bottom of the list.

**adviseAttachedBehaviors**

    Called by the window itself - sends a window message to all currently attached window behaviors that handle it (those that have on_{MessageName} methods).

>**msg** - the windowing message.

    Although it is possible to send message to the behaviors without sending it to the window, this is not recommended, because it can bypass some vital part of the window's specific functionality.

**attachedBehavior**

    Finds and returns the first attached behavior that either is selected by the callback or is attached with the specified name.

>**callback_or_name** - This can be a callback or a string specifying the name of the attached behavior to return.

>**returns** the first found behavior or null otherwise.

**callback**

This argument can be given to some of the interface methods to select one or more attached behaviors. The callback can be the usual callback in BindKraft, but as it needs to return `true` in order select a behavior only a `function` or a `Delegate` will make sense to be passed. The prototypes is

`function(behavior): returns boolean`

For example a callback looking for a specific class name will look like this:

```Javascript
function (behavior) {
    if (BaseObject.is(behavior,"MySpecificBehaviorClassName")) return true;
    return false;
}
```

To pack an instance method as callback use `new Delegate(this,this.theMethod)`.

repository: Cleancodefactory/BindKraft

repo_name: Cleancodefactory/BindKraft


text:
<!--Put badges at the very top -->
> Note: We don't need no stinkin' badges. We don't CI this or track deployments.

> TODO: Should we add travis and run the included tests if they work?

# Watson News Intelligence starter kit

> TODO: Reverse engineer and document:
   * what the kit does (intro and overview)
   * goals
   * architecture
   * flow
   * components used, featured tech
   * sample output
   * troubleshooting tips
   * links
   * add section(?) to refer to the actual starter kit

In this Code Pattern, we will [create something] using [technologies] and [components]. [Explain briefly how things work]. [Give acknowledgements to others if necessary]

When the reader has completed this Code Pattern, they will understand how to:

* [goal 1]
* [goal 2]
* [goal 3]
* [goal 4]

![](doc/source/images/architecture.png)

## Flow
1. Step 1.
2. Step 2.
3. Step 3.
4. Step 4.

<!--Update this section-->
## Included components
Select components from [here](https://github.ibm.com/developer-journeys/journey-docs/tree/master/_content/dev#components), copy and paste the raw text for ease
* [Component](link): description
* [Component](link): description

<!--Update this section-->
## Featured technologies
Select components from [here](https://github.ibm.com/developer-journeys/journey-docs/tree/master/_content/dev#technologies), copy and paste the raw text for ease
* [Technology](link): description
* [Technology](link): description

# Watch the Video
> We don't do videos for starter kits, right?

# Steps
Use the ``Deploy to IBM Cloud`` button **OR** create the services and run locally.

## Deploy to IBM Cloud

[![Deploy to IBM Cloud](https://bluemix.net/deploy/button.png)](https://bluemix.net/deploy?repository=https://github.com/markstur/skit-watson-news-intelligence)

1. Press the above ``Deploy to IBM Cloud`` button and then click on ``Deploy``.

2. In Toolchains, click on Delivery Pipeline to watch while the app is deployed. Once deployed, the app can be viewed by clicking 'View app'.

3. To see the app and services created and configured for this Code Pattern, use the IBM Cloud dashboard. The app is named `WatsonNewsIntelligence` with a unique suffix. The following services are created <!-- and easily identified by the `wbc-` prefix -->:
    * watson-news-intelligence-discovery-1525714616589

## Run locally
> NOTE: These steps are only needed when running locally instead of using the ``Deploy to IBM Cloud`` button.

1. [Clone the repo](#1-clone-the-repo)
2. [Create Watson services with IBM Cloud](#2-create-watson-services-with-ibm-cloud)
5. [Configure credentials](#5-configure-credentials)
5. [Run the application](#6-run-the-application)

### 1. Clone the repo

Clone the `skit-watson-news-intelligence` locally. In a terminal, run:

```
$ git clone https://github.com/markstur/skit-watson-news-intelligence
```

### 2. Create Watson services with IBM Cloud

Create the following services:

* [**Watson Discovery**](https://console.ng.bluemix.net/catalog/services/discovery)

### 5. Configure credentials

The credentials for IBM Cloud services (Discovery), can be found in the ``Services`` menu in IBM Cloud,
by selecting the ``Service Credentials`` option for the service.

Copy the Discovery credentials JSON into your local repos `server/localdev-config.json` file.

#### Example `server/localdev-config.json`:

```json
{
  "watson_discovery_url": "https://gateway.watsonplatform.net/discovery/api",
  "watson_discovery_username": "a111aaaa-1a1a-111a-a11a-1aaa1111aaa1",
  "watson_discovery_password": "aaAAA1aaaAaa"
}
```

### 6. Run the application
1. Install [Node.js](https://nodejs.org/en/) runtime or NPM.
1. Start the app by running `npm install`, followed by `npm start`.
1. Use your browser to try the web UI at `localhost:3000`.

# Sample output

Enter a company name in the search bar to query Watson Discovery News through the app. Each panel on the page contains a visual presentation of insights derived from the API response. Press `View Query` in each panel to view the parameters of the API request and the response in JSON form.

For your first search, enter the name of a company (or some news topic) and hit enter or click on the magnifying glass icon.

![](doc/source/images/first_search.png)

After your first search, you can change the search term, and you can specify the time period for your search.

![](doc/source/images/later_search.png)

The results will include the following sections.

## Top Entitites
**Top Entities** shows a word cloud showing frequently mentioned entities for your search term. The words are sized to indicate their significance. You can click on the tabs to show entities that are topics, companies, or people.

## Top Stories
**Top Stories** shows a the top news stories that matched your search. You can sort the articles by relevance or by date.

## Sentiment Analysis
**Sentiment Analysis** shows the postitive/neutral/negative sentiment breakdown of the news articles from a variety of news sources.

## Anomaly Detection
**Anomaly Detection** shows the number of articles over the specificed time period and highlights anomalies, if any, with a red dot. You can hover over the chart to get additional details about each data point -- including an example headline.

## Co-Mentions & Trends
**Co-Mentions & Trends** shows entities that are commonly co-mentioned with your search entity and charts the trend for each entity pair. The chart tracks positive and negative sentiment for the pair over time. The total number of mentions and overall sentiment is also listed for each co-mentioned entity pair.

## Screenshot

Example results from a week with Hawaiian volcano activity:

![](doc/source/images/sample_output.png)

# Troubleshooting

* Error placeholder

  > Explanation placeholder

# Links
*
*
*

# Learn more

* **Artificial Intelligence Code Patterns**: Enjoyed this Code Pattern? Check out our other [AI Code Patterns](https://developer.ibm.com/code/technologies/artificial-intelligence/).
* **Data Analytics Code Patterns**: Enjoyed this Code Pattern? Check out our other [Data Analytics Code Patterns](https://developer.ibm.com/code/technologies/data-science/)
* **AI and Data Code Pattern Playlist**: Bookmark our [playlist](https://www.youtube.com/playlist?list=PLzUbsvIyrNfknNewObx5N7uGZ5FKH0Fde) with all of our Code Pattern videos
* **With Watson**: Want to take your Watson app to the next level? Looking to utilize Watson Brand assets? [Join the With Watson program](https://www.ibm.com/watson/with-watson/) to leverage exclusive brand, marketing, and tech resources to amplify and accelerate your Watson embedded commercial solution.
* **Kubernetes on IBM Cloud**: Deliver your apps with the combined the power of [Kubernetes and Docker on IBM Cloud](https://www.ibm.com/cloud-computing/bluemix/containers)

# License
[Apache 2.0](LICENSE)

> Below the following line is copied from the starter kit. Those steps assume you used the starter kit UI and so you would already have a service created.

♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺
♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺
♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺
♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺ ♺
# Watson News Intelligence starter kit [![](https://img.shields.io/badge/bluemix-powered-blue.svg)](https://bluemix.net)

The Watson News Intelligence starter kit for Node.js visualizes the results of [Discovery](https://www.ibm.com/watson/services/discovery) queries. The app searches [Discovery News](https://www.ibm.com/watson/services/discovery-news) data to get insights from the news, including related concepts, entities, and sentiment trends.

## Getting started

### Running locally

These instructions are for running locally with Node.js. You can also [run locally with Docker](#running-locally-with-docker).

1. Install [Node.js](https://nodejs.org) ([LTS](https://github.com/nodejs/Release) supported versions).

1. At the command line, go to your project directory.

1. Install the dependencies:

    ```sh
    npm install
    ```

1. Start the app:

    ```sh
    npm start
    ```

1. Point your browser to [localhost:3000](http://localhost:3000).

### Testing the application

Enter a company name in the search bar to query Watson Discovery News through the app. Each panel on the page contains a visual presentation of insights derived from the API response. Press **View Query** in each panel to view the parameters of the API request and the response in JSON form.

### Deploying to IBM Cloud as a CloudFoundry application

1. To deploy your project to IBM Cloud, you will need to install the [Bluemix CLI](https://console.bluemix.net/docs/cli/reference/bluemix_cli/get_started.html#getting-started). Open a terminal and run the command that corresponds with your operating system:

    - MacOS

        ```sh
        sh <(curl -fsSL https://clis.ng.bluemix.net/install/osx)
        ```

    - Linux

        ```sh
        sh <(curl -fsSL https://clis.ng.bluemix.net/install/linux)
        ```

    - Windows Powershell

        Copy and paste the following command into a Windows PowerShell terminal console and execute it.

        ```sh
        iex(New-Object Net.WebClient).DownloadString('https://clis.ng.bluemix.net/install/powershell')
        ```

1. Set your API endpoint. Check the top right corner of your [IBM Cloud dashboard](https://console.bluemix.net/dashboard) to determine which of the following Regions your account is set to, then run the corresponding command to set your API Endpoint.

    - US South:

        ```sh
        bx api https://api.ng.bluemix.net
        ```

    - Germany:

        ```sh
        bx api https://api.eu-de.bluemix.net
        ```

    - Sydney:

        ```sh
        bx api https://api.au-syd.bluemix.net
        ```

    - United Kingdom:

        ```sh
        bx api https://api.eu-gb.bluemix.net
        ```

1. In your terminal go to your Project folder and run the following command to login to your IBM Cloud account with your IBM Cloud username and password.

    ```sh
    bx login
    ```

1. Push the app to IBM Cloud:

    ```sh
    bx app push
    ```
    The app will be deployed using the settings in your project's `manifest.yml` file.

1. Access your app at the URL specified in the command output.

    After your app is deployed, you can manage it from your [IBM Cloud dashboard](https://console.bluemix.net/dashboard/apps).

### Directory structure

```none
.
├── .bluemix                        // bluemix files
├── chart                           // helm chart files for Kubernetes
├── public                          // static resources
├── server                          // server app
│   ├── config                      // express configuration
│   ├── routers                      // express routers
│   ├── services                     // express services
|   └── server.js                    // entry point
├── test                             // tests
├── manifest.yml
├── package.json
└── views                           // react components
```

## Managing your project in the Watson Console

Select your project from the [Projects list](https://console.bluemix.net/developer/watson/projects) in the Watson developer console. From the project page, you can do the following:

    - Add additional services to your project
    - View documentation and credentials for your project's services
    - Configure a DevOps toolchain

## Running locally with Docker

1. Run the command that corresponds with your operating system to install the [IBM Cloud Developer Tools CLI](https://console.bluemix.net/docs/cloudnative/dev_cli.html):

    - MacOS or Linux:

        ```sh
        curl -sL https://ibm.biz/idt-installer | bash
        ```

    - Windows 10:

        ```sh
        Set-ExecutionPolicy Unrestricted; iex(New-Object Net.WebClient).DownloadString('http://ibm.biz/idt-win-installer')
        ```

1. Download and install [Docker](https://www.docker.com/).
1. If you installed any node dependencies into your project folder, remove them. Open a terminal and run the following command from your project folder, where your starter kit code is:

    ```sh
    rm -rf node_modules
    ```

1. Build the Docker container:

    ```sh
    bx dev build
    ```
    The build may take a few minutes to complete.

1. Run the Docker container:

    ```sh
    bx dev run
    ```

1. Point your browser to [localhost:3000](http://localhost:3000).

## License

  This sample code is licensed under Apache 2.0.

## Open Source @ IBM

  Find more open source projects on the [IBM Github Page](http://ibm.github.io/)

repository: markstur/skit-watson-news-intelligence

repo_name: markstur/skit-watson-news-intelligence


text:
# CID19

Connect ID is a website developed to bring people with ideas together with people who can realize those ideas.
By signing up the user can search or add projects with description of a certain project or idea. Users who want to contribute to these
projects can get in contact with the one who put the project on the website and discuss options and make further arrangements.

## This project makes use of following programs
[![Browserstack-logo@2x](https://user-images.githubusercontent.com/34754166/55586482-530ac080-5729-11e9-92f5-2289b5f479e6.png)](http://browserstack.com)
[![bugsnag](https://user-images.githubusercontent.com/34754166/55588366-ddedba00-572d-11e9-9e74-d0776c15da16.png)
](https://www.bugsnag.com/)


text:
# Exceptionless AKS POC
Please refer to the official Exceptionless repo for details - https://github.com/exceptionless/Exceptionless

The purpose of this fork was to setup a POC environment to get Exceptionless running in AKS

# To get this working
In order to get this working, check out the ex-poc-setup.sh file.

You will need to do this run these command first

rm -rf Exceptionless

git clone https://github.com/ahmedsza/Exceptionless.git

cd Exceptionless/k8s

then run the ex-poc-setup.sh file

repository: ahmedsza/Exceptionless

repo_name: ahmedsza/Exceptionless


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

### Description

An unauthenticated command injection vulnerability exists in multiple parameters in the Gryphon Tower router’s web interface at /cgi-bin/luci/rc. An unauthenticated remote attacker on the same network can execute commands as root on the device by sending a specially crafted malicious packet to the web interface.

### POC

#### Reference
- https://www.tenable.com/security/research/tra-2021-51

#### Github
- https://github.com/ARPSyndicate/cvemon
- https://github.com/SYRTI/POC_to_review
- https://github.com/ShaikUsaf/frameworks_base_AOSP10_r33_CVE-2021-20138
- https://github.com/WhooAmii/POC_to_review
- https://github.com/manas3c/CVE-POC
- https://github.com/nomi-sec/PoC-in-GitHub
- https://github.com/trhacknon/Pocingit