teleren/devto huggingface dataset:
Mapping your npm scripts with npmapper
Tags: npm, node, javascript, webdev
Published: 2019-11-02 09:00:52

One of the cool features of npm is the ability to run procedures which can be defined under the project's `package.json` file. 
I'm pretty sure that if you are reading this post you also have a few npm scripts under your project's package.json file and are wondering what "mapping" them means…

Large projects usually contain large number of npm scripts. You have a script for testing, for building, for linting, etc. Those scripts usually are the aggregation of a number of other building blocks, for example, a test script is made out of unit testing, e2e testing and other testing aspects which are composed together.

But while creating these "lego-bricks" and composing them together gives you great flexibility, it makes your package.json file very hard to understand and maintain. What calls what? what params are passed to a command? are there any duplications? 
We need something to inspect our scripts and map them so it will be easy to read and understand them. At least I needed it…

So I have created **npmapper**

npmapprer is an npm CLI tool which lets you map your npm scripts in a human-friendly way to get a good overview on what's really going on in your package.json file. 
Just run `npx npmapper` on your project and you will get a nice HTML report on your browser.
They say a picture is worth a thousand words so here is an image of an HTML report example of running npmapper on **Vue.js** package.json file, only for the test script:

![vue.js test script mapped](https://thepracticaldev.s3.amazonaws.com/i/oz19jw9tv2dgwmktujl7.png)
*vue.js test script mapped ^*

You can see in the image above exactly what are the steps which run under the test script. You can drill into each and see its parameters or sometimes what delegation it does to another script (or in some projects even to another project's package.json).

You can decide whether you want to map the entire scripts or just the one which interests you, or perhaps you'd like the outcome to be a JSON report instead of HTML one.

Wanna try it? simply run `npx npmapper` on your project containing a package.json file and the result will pop on your browser.
Wanna read more details? Here is the [Github repo](https://github.com/mbarzeev/npmapper) and the [NPM page](https://www.npmjs.com/package/npmapper) for the project.

And of course, I would love to hear any suggestions, comments or feedback you might have on the tool. Happy mapping :)
How to allow Touch ID to authenticate for Sudo commands on Mac
Tags: productivity, tutorial
Published: 2019-11-02 08:26:42

To enable TouchID on your Mac to authenticate you for sudo access instead of a password you need to do the following steps.

- Open Sudo configuration file with the following command

``` sudo vi /etc/pam.d/sudo ```

Initially file content should look like this

```
# sudo: auth account password session
auth       required       pam_opendirectory.so
account    required       pam_permit.so
password   required       pam_deny.so
session    required       pam_permit.so
```

- Paste `auth sufficient pam_tid.so` on line 2 of the document (underneath the initial comment line)

After pasting contents should be like this

```
# sudo: auth account password session
auth       sufficient     pam_tid.so
auth       required       pam_opendirectory.so
account    required       pam_permit.so
password   required       pam_deny.so
session    required       pam_permit.so
```

- Save the file (Since this file is read-only, you may be required to do force save, Eg `vim` will require you to use `wq!` when saving)

- Now try to use sudo command on terminal and you should be prompted to authenticate with Touch ID as shown below


![Screenshot 2019-11-02 at 1.13.51 PM.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1572680707181/dnTJUzFIm.png)

- If you click 'Cancel' you can just enter your password at the terminal prompt if you click 'Use Password' you can enter your password in the dialog box.

- If you SSH into your machine it will fall back to just use your password since you can't send your TouchID fingerprints over SSH


- If you're using **iTerm2** (v3.2.8+) you may have seen Touch ID failing to work with sudo in the terminal despite having made the pam_tid.so modification as above, and it works in previous versions. This is down to an advanced feature that seems to be now enabled by default - this needs to be turned off here: **iTerm2->Preferences > Advanced > (Goto the Session heading) > Allow sessions to survive logging out and back in.**


![Screenshot 2019-11-02 at 1.17.56 PM.png](https://cdn.hashnode.com/res/hashnode/image/upload/v1572680888792/ocxzOZYT5.png)


Reference: https://apple.stackexchange.com/questions/259093/can-touch-id-for-the-mac-touch-bar-authenticate-sudo-users-and-admin-privileges
Create an Online Resume using Gatsby
Tags: gatsby, react
Published: 2019-11-02 07:56:06

I developed a gatsby starter to create an online resume. I  used <a href="https://material-ui.com/">Material UI</a> for the theming.

Check the Demo <a href="https://donvito-gatsby-resume-starter.netlify.com">https://donvito-gatsby-resume-starter.netlify.com</a>

![Online Resume](https://github.com/donvito/donvito-gatsby-resume-starter/raw/master/src/images/resume-starter.png)

## 🚀 Quick start

1. Download the starter code from this repo.

{% github donvito/donvito-gatsby-resume-starter %}    

2.  **Add the data to be populated for your resume**

    Edit the following files:

    1.  **`src/data/summary.json`**: This data file is used to populate the Summary section.

    2.  **`src/data/contact.json`**: This data file is used to populate the Contact section.

    3.  **`src/data/experience.json`**: This data file is used to populate the Experience section.

    4.  **`src/data/skill.json`**: This data file is used to populate the Skills section.

3.  **Start the site.**

    Navigate into your new site’s directory and start it up.

    ```sh
    cd donvito-gatsby-resume-starter/
    gatsby develop
    ```

4.  **Access the site!**

    Your site is now running at `http://localhost:8000`!

    _Note: You'll also see a second link: _`http://localhost:8000/___graphql`_. This is a tool you can use to experiment with querying your data. Learn more about using this tool in the [Gatsby tutorial](https://www.gatsbyjs.org/tutorial/part-five/#introducing-graphiql)._

    Open the `donvito-gatsby-resume-starter` directory in your code editor of choice and edit `src/pages/index.js`. Save your changes and the browser will update in real time!

## 💫 Deploy the sample in Netlify

[![Deploy to Netlify](https://www.netlify.com/img/deploy/button.svg)](https://app.netlify.com/start/deploy?repository=https://github.com/donvito/donvito-gatsby-resume-starter)
Shopify Webshop System: Frequently Asked Questions and Tips
Tags: design, javascript, shopify, beginners
Published: 2019-11-02 07:30:32

When it comes to building an online store using Shopify, the same questions keep coming up. Here they are answered briefly and concisely:

 

How much does Shopify cost?
There are three different rates:

Basic Shopify

Monthly $ 29 at monthly contract
Monthly $ 26 at annual contract
Transaction fees 2%
For beginners: Unlimited number of products, German support
More details on the Shopify prices page

 

Shopify

Monthly $ 79 at monthly contract
Monthly $ 71 at annual contract
Transaction fees 1%
For growing sales: advanced e-commerce features
 

Advanced Shopify

Monthly $ 299 at monthly contract
Monthly $ 266 on annual contract
Transaction fees 0.5%
For push-throughs: More detailed report function, shipping costs are calculated automatically
Payment is always in US dollars by credit card.

 

What do the individual Shopify tariffs offer?
Always there is a fully customizable shop, a blog, unlimited product range, sales through marketplaces and social media, payment by credit card, DSGVO-ready, 24/7 support.

Shopify tariff: Provides a professional reporting feature that lets  you analyze shop performance.

Advanced Shopify tariff:  Offers even deeper performance insights with customizable reports.

 

What are transaction fees?
Transaction fees apply when a customer pays by credit card or Paypal. They will not be charged if Shopify Payments is used as payment gateway.

 

Can I try Shopify for free?
There is a 14-day free trial period. You can create articles and make test purchases. If it comes to a real sale, however, there are fees.

 

How can I cancel Shopify?
You can temporarily pause a Shopify account. You can completely close your shop in the admin area on the bottom, account '. Here the account must be closed manually. This is only possible if there are no outstanding invoices.

To the Shopify website

 

What does the Shopify Appstore offer?
Here are Shopify supplements and shop extensions. Partially free third-party apps like Amazon integration or dropshipping. There are more than 2000 apps and tools available.

Do you want to create Shopify store? Then hire the best shopify developer from here: http://www.votivetech.com/service/shopify-design-development-services/
Zen Buddhism Inspired EQ: Shoshin
Tags: inclusion, eq, leadership
Published: 2019-11-01 21:29:30

The key to developing your emotional intelligence (EQ) is continuous practice and iteration. Similar to learning a new coding language, books and Stack Overflow can only take you so far. Most learning happens by doing.

A simple, yet difficult, mechanism to practice that will help build up your EQ is something called shoshin.

According to wikipedia:

> Shoshin is a word from Zen Buddhism meaning “beginner's mind.” It refers to having an attitude of openness, eagerness, and lack of preconceptions when studying a subject, even when studying at an advanced level, just as a beginner would.

The “beginner’s mind” philosophy is exactly what it sounds like: approaching things like you are beginner. When you are beginner, what do you typically do?

- Slow down to make sure you understand all points
- Ask clarifying questions
- Practice a concept, then show your steps to make sure you haven’t missed anything

    Repeat your interpretation of a concept back to the person speaking to you

## Why is this difficult?

What makes shoshin difficult to master is it can feel like it’s in direct conflict with your career and reputation.

You’re paid to know, right?

You’re likely a subject matter expert or team leader. You’re likely depended on within your team to know the answers.

If your goal, however, is to improve your team culture and your personal emotional intelligence, you need to practice asking questions even if you know the answer. Asking questions unlocks the “beginner’s mind”.

## Asking questions develops EQ

If shoshin is all about beginner’s mind, and beginner’s ask questions, how can asking questions help develop my EQ?

Glad you asked! Let’s break it down.

Read the rest over at [EQ for Devs](https://eqfordevs.substack.com/p/zen-buddhism-inspired-eq-shoshin).
Polygon Image Annotation
Tags: polygonimageannotation
Published: 2019-11-02 07:00:06

---
title: Polygon Image Annotation
published: true
description: Polygon image annotation service for computer vision object detection through machine learning.
tags: Polygon Image Annotation
---
![Alt Polygon Image Annotation](https://thepracticaldev.s3.amazonaws.com/i/b5y14obzx2h9uwsj0dqi.jpg)

[Polygon image annotation](https://www.cogitotech.com/polygon-annotation/) service for computer vision object detection through machine learning. Detecting the irregular shapes or coarse objects, polygonal annotation helps autonomous vehicles, detect the road surface marking and other printed signs on roads making the autonomous driving successful and safe. 

The polygon semantic segmentation for irregular shapes helping visual perception model observe the different scenario with right level of accuracy. Object localization through areal view imagery is also possible with polygon-annotation services. 

Cogito is an expert in making the object of interest recognizable to machines through polygon annotation service by team of annotators while ensuring the level of accuracy. It is providing the high-quality [training data for AI](https://www.cogitotech.com/) and machine learning algorithm training for different sectors including healthcare, retail, automotive and agriculture etc.
Python Wrap Up - October 2019
Tags: python, bestofdev, top7
Published: 2019-11-02 05:44:27

Hi! I'm Vicente, your friendly Filipino mod for the #python tag. Today is another episode of the Top Python Posts of the month!

At the end of each month, I'll be curating the top #python posts based on traffic & engagement.

# 1.) What software technologies will earn you the highest pay?

Whether you’re a seasoned pro or just getting started, as a developer it’s important that you stay on the lookout for opportunities to learn new languages, fameworks, and tools. This is crucial if you want to stay relevant and competitive in today’s job market, as well as increase financial reward.

{% link https://dev.to/educative/what-software-technologies-will-earn-you-the-highest-pay-3fc3 %}

# 2.) A Free Ebook on Greedy Algorithms, Divide & Conquer, and Dynamic Programming 

Most of the problems you'll encounter within Dynamic Programmg already exist in one shape or another. Often, your problem will build on from the answers for previous problems. Here's a list of common problems that use Dynamic Programming.

{% link https://dev.to/brandonskerritt/a-free-ebook-on-greedy-algorithms-divide-conquer-and-dynamic-programming-1712 %}

# 3.) Good and Bad Practices of Coding in Python 

Python is a high-level multi-paradigm programming language that emphasizes readability. It’s being developed, maintained, and often used following the rules called The Zen of Python or PEP 20.

{% link https://dev.to/duomly/the-best-practices-of-coding-in-python-and-what-to-avoid-3c65 %}

# 4.) 20 useful Python tips and tricks you should know 

Python is a popular, general-purpose, and widely used programming language. It’s used for data science and machine learning, scientific computing in many areas, back-end Web development, mobile and desktop applications, and so on. Many well-known companies use Python: Google, Dropbox, Facebook, Mozilla, IBM, Quora, Amazon, Spotify, NASA, Netflix, Reddit, and many more.

{% link https://dev.to/duomly/20-useful-python-tips-and-tricks-you-should-know-3h8c %}

# 5.) Best Python framework for building a desktop application and GUI 

Python has been the most trending programming language used for object oriented progamming. With python you can run simple statement over and over again without having to compile a whole program of which it's output functionality is superb. 

{% link https://dev.to/codesharedot/best-python-framework-for-building-a-desktop-application-and-gui-58n5 %}

That wraps up the top [#python](https://dev.to/t/python/) posts for October. If you'd like to read more, check out [#python](https://dev.to/t/python/) or follow [The Python Dev](https://twitter.com/The_Python_DEV) on Twitter!
RASA boilerplate chatbot templates
Published: 2019-11-02 05:31:39

---
title: RASA boilerplate chatbot templates
published: true
description: 
tags: 
---

We have started publishing RASA boilerplate chatbot templates for multiple use cases. 

It contains the minimal conversation skeleton, that will help you get started with each use case. Go to botartsans.com to browse and download the template zip file. 

Github: https://github.com/cedextech/Rasa-Chatbot-Templates

**How to use it?**

Here are the simple steps that you can follow to use a template:

- Install RASA https://rasa.com/docs/rasa-x/installation-and-setup/
- Create a project_directory for your project
- Initialize RASA within your project_directory by running command rasa init
- Replace the files in the project_directory with the ones from downloaded template
- Train the bot with command rasa train
- Evaluate the bot in the terminal with command rasa test
- Start talking to the bot in the terminal with command rasa shell

Don’t forget to flesh up the NLU and Stories files for real use cases running the command Rasa interactive or Rasa X. Keep revisiting, to find new templates added to the list.
365 Days of Coding Challenge: Day 1
Tags: codingphase, coding365challenge, selftaugt
Published: 2019-11-02 04:00:10

---
title: 365 Days of Coding Challenge: Day 1
published: true
description: My journey to consistency begins!
tags: #CodingPhase #Coding365Challenge #selftaugt
---
<p>
Today I decided to take part in <a href="http://www.codingphase.com" target="_blank">Joe Santos' (aka CodingPhase.com)</a> coding challenge where I will be coding for an entire year.</p>

I made this decision kind of late in the day so the only thing I have to show off today is a simple HTML "Hello World" page using Bootstrap.  Free free to see the screenshot below and the link to the CodePen. I hope it is not too late. 

https://codepen.io/idrissalemairethiam/pen/xxxpdJw

![Day 1 of my Coding365 Challenge attempt.  I humbly ask that you do not despise small beginnings.](https://thepracticaldev.s3.amazonaws.com/i/ryn2cue1w6z6wxls1eoz.png)
New Year’s Resolution: Teach coding in your organization
Tags: javascript, codenewbie
Published: 2019-11-02 03:27:18

As we are approaching New Year it is time to think of new resolutions that we’ll work on in 2020. I’m sure you already have by now a lot of ideas on your list.

I’m challenging you to accept a new resolution... that may sound a little bit extreme at first sight: **if you have software development skills, teach non-technical people from your organization how to code!**

I guarantee you that you’ll create a lot of interest and a lot of people will join your class. Make the invitation open to people from all the departments.

The success of this project is to keep it simple: no books, no powerpoints. Just a conference room with a whiteboard and a projector. Ask everyone to bring their laptops and spend 1 hour quality time writing code and scribbling on the whiteboard.

One more condition: do it in a way that doesn’t impact your daily business activities. Perhaps in the lunch room or after hours. And do it for the entire 2020!

What will happen next will be impressive: you’ll see how people are happily skipping lunch and take time out of their busy schedule just to challenge themselves with intellectual activities in your class. You’ll see how a new creative and engaging environment starts to build in your organization...

Steve Job said “Everybody in this country should learn to program a computer, because it teaches you how to think”.

Introduce the program gently to your colleagues. Encourage them to grow themselves into this new area. Not all of them will become coders … but having coding knowledge will surely help them better with their personal goals and organization goals.

Remember them that even president Obama took the [challenge](https://www.whitehouse.gov/blog/2014/12/10/president-obama-first-president-write-line-code) to code

Start now! ... and if you managed to create new programmers in your organization drop me a line! I’m always happy to hear success stories!

> Bonus tip: For a maximum fun, you can make mini-games together on a coding platform intended for beginners such as [codeguppy.com](https://codeguppy.com). Give adults the chance to feel like kids again!

[![JavaScript projects](https://thepracticaldev.s3.amazonaws.com/i/fwck1mxuv79ay3ejirq1.png)](https://codeguppy.com)
How to build sites for personal ease and client satisfaction?
Tags: webdev, cms, html, css
Published: 2019-11-02 02:21:13

This is my dilemma. There are a number of website's I am undertaking the 'development' of, my only experience thus far is a few test files courtesy of Colt Steeles web dev bootcamp. This taught me a decent enough grasp of HTML + CSS to feel confident enough to build a small single page site using the two, then deploying the landing page via Netlify. 

The projects I am undertaking are fairly basic, one being a recruitment site with basic form functionality, another a childcare consultancy with the same and finally an auction site potentially with a built in user management system. 
Each of them has been custom designed by my girlfriend and I am sure I can recreate them using HTML, CSS + JS. However, the clients will most likely want to update content themselves at some stage and it does not seem to be A popular option from what i have gathered for developers to maintain this aspect of the sites for clients, even if it means the client themselves creating the content and the developer updating it.

My concern is that I won't be able to recreate the design using A CMS or are there some options that are very customization or should I use something like GATSBY to build the site and then host on a CMS?
How I tackle these will have a big impact on the future of an awesome side business that me and my partner are considering.

Any suggestions are welcome :)
set cookies for cross origin requests
Tags: webdev
Published: 2019-11-02 02:06:35

When `http://portal` sent a request to `http://auth`, `http://auth` failed to set user's cookie.

Set credential flag for request and modified the following response headers to fix it [[1]](https://stackoverflow.com/questions/46288437/set-cookies-for-cross-origin-requests), [[2]](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Access-Control-Allow-Origin):
- Access-Control-Allow-Origin (request.Header.Origin, no wildcard allowed)
- Vary (Origin)
- Access-Control-Allow-Credentials (true)

And we can followe [w3schoool article](https://www.w3schools.com/xml/xml_http.asp) to test cross domain request by browser console.
```javascript
var xhttp = new XMLHttpRequest();
xhttp.onreadystatechange = function() {
    console.log(this);
};
xhttp.open("GET", "http://auth", true);
xhttp.send(); 

```