teleren/devto huggingface dataset:
When find can't find
Tags: linux, bash, find
Published: 2019-10-28 09:53:42

---
title: When find can't find
published: true
date: 2019-08-27 00:00:00 UTC
tags: linux,bash,find
canonical_url: https://foursixnine.io/blog/tech/2019/08/27/When-find-can't-find.html
---

If you happen to be using [gnu find](http://man7.org/linux/man-pages/man1/find.1.html) in the deadly combination with a directory that is a symlink (you just don’t know that yet), you will find face the hard truth that running:

`find /path/to/directory -type f`

Will return _zero_, **nada** , _nichts_, ~~meiyou~~ , which is annoying.

![where is it!](https://media.giphy.com/media/clupdT5vHL9GifMlnC/giphy.gif)

this will make you question your life decisions, and your knowledge on tools that you use daily, only to find out that the directory is actually a symlink :).

So next time you find yourself using `find` and it returns nothing, but you are sure that your syntax is correct and get no errors, try adding the `--fowllow` or use the `-L`

` find -L /path/to/directory/with/symlink -type f`

This will do what you want :)

![Here is it!](https://media.giphy.com/media/1FnPDkhFZDgoU/giphy.gif)
Rename variables while destructuring
Tags: javascript, tutorial, webdev, showdev
Published: 2019-11-01 15:47:18

---
title: Rename variables while destructuring
published: true
tags: ['javascript', 'tutorial', 'webdev', 'showdev']
canonical_url: https://learnwithparam.com/blog/rename-while-destructuring/
description: Destructuring is a great feature and has many use cases. Today, we will see how to rename a variable while destructuring and some use cases for it.
---

In my last tutorial, I covered destructuring in JavaScript briefly. If you haven’t know, what is destructuring and how to set default values while destructuring. Please check it out [here](https://learnwithparam.com/blog/default-values-while-destructuring-in-javascript/)

Before jumping on to renaming inside destructuring, we will see few of the cases when this is needed.

- When the object returned from server doesn’t have better key names. Example,

```js
const obj = {
  prop1: 'Param',
  prop2: 26,
};
```

In the above snippet, nobody knows what is prop1 and prop2 without knowing the details of the backend. If we destructure and use the same variable, it will make the front end code unreadable and undebuggable later on.

- When there is similar object props in two different objects. Example,

```js
const obj1 = {
  name: 'Param',
  age: 26, // same key `age` present in obj2
};

const obj2 = {
  firstName: 'Ahmed',
  lastName: 'John',
  age: 29, // same key `age` present in obj1
};
```

Now, both the object have `age` key, we can’t destructure both the variable as age. Instead, we need to rename either one of those.

Lets see how to do that,

for the example 1, this is how it can be destructured and renamed.

```js
const { prop1: name, prop2: age } = obj;
console.log(name, age); // Param, 26
```

for the example 2,

```js
const { age: ageOfParam, ...restOfParam } = obj1;
const { age: ageOfAhmed, ...restOfAhmed } = obj2;

console.log(ageOfParam, ageOfAhmed); // 26, 29
```

Isn't it the syntax very easy to use? 😎

```js
// Syntax

const { propKey: NewVariableName } = Object;
```

Destructuring is very powerful in javascript, it has lot of use cases and make the developers life easier with several usecases.

Checkout the examples here,

{% codesandbox rename-while-destructuring-6qrob %}
What is the correct road for DevOps
Tags: devops, linux, docker
Published: 2019-08-26 23:04:03

---
title: What is the correct road for DevOps
published: true
description:
tags: devops,linux, docker
---

Hello,

about a few weeks ago, in my company they've offered me the position as DevOps Jr (Actually i'm a senior dev).

Being honest, i'm a little newbie on that field.

I've started research in order to make a list (pretty like a roadmap) for learn from linux to docker:

There is my list:

Linux (Commands)
Docker, basic commands
Git commands for deployment
Docker compose
Docker Swarm
Bamboo
AWS
Jenkis (Optional)
Python (Optional)

So, what do you think about this list? it is the correct path for start in this world?

Regards, 

Andres
Quick and easy alias for Laravel
Tags: laravel, shortcuts, development
Published: 2019-08-26 22:55:56

---
title: Quick and easy alias for Laravel
published: true
description: Are you tired of typing 'php artisan' every time you need to create a controller or clear some configuration cache? This alias will save you some keystrokes and make you happier. 
tags: laravel, shortcuts, development
---
## Alias for PHP ARTISAN

If you are on a Linux or Mac machine...

Open up your ~/.bash_profile with your favorite text editor and add the following line at the end of the file:

```bash
alias a="php artisan"
```

Save the file and load it for the current terminal profile with:

```bash
source ~/.bash_profile
```

* *- the next time you log onto a terminal window it should already be working* 

## Lazy 'php artisan' 

Now instead of typing in all those nasty characters 'php artisan' all you need to do is type `a` followed by your favorite command!

instead of typing: 

```bash
php artisan view:clear
php artisan queue:restart
php artisan make:controller
```

You can now do: 
```bash
a view:clear
a queue:restart
a make:controller
```

Isn't that a blessing?
How I went from charging $100 to $10,000+ for a website 
Tags: freelance, webdev, career
Published: 2019-08-26 22:41:16

---
title: How I went from charging $100 to $10,000+ for a website 
published: true
description: In this video I'm sharing how I went from charging $100 and a coffee card to $10,000 (sometimes more) per website/app as a freelance web developer.
tags: freelance, webdev, career,
---

 
##Freelance web development is lucrative. 

Companies and other organizations have a LOT of problems...Often these problems can be solved with the help of a website. 

But websites aren't what they were in the '90s! These days a "website" can refer not only to a site (i.e. a WordPress site or a static site), but also can extend to (or incorporate) web apps, integrations & APIs and SO much more. 

As a freelancer, commanding $10K for one project is fantastic but I'm still busy building my portfolio and social proof for a higher tier. Because there really is no limit to how much you can charge, as long as you bring results and can prove that you're responsible for those results.

***

###It's not easy... And it takes time. But it *can* be done.

 Sound interesting? I produced a top-rated book and video course that shows you exactly how to get started. 

👉Freelance Newbie book: https://amzn.to/2WWtFNq
👉Freelance Newbie Udemy course ($9.99 coupon): https://www.udemy.com/freelance-newbie/?couponCode=RTC-YOUTUBE

***

_This video originally appeared on www.youtube.com/realtoughcandy_.
Come follow me there!
How do you add images to the feed for a post?
Tags: help, meta
Published: 2019-08-26 22:39:02

I tried using `cover_image` in the metadata. That applied an image to the post itself, but the image didn't appear in feeds for that image. For example, images appear like the following:

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/eh5ujzxf4tjbdwxigjxo.png)

Is there something additional you need to do in order to make this happen?


Here are my guesses:
1.) Cover images need to fix certain width/height constraints to appear in the feeds
2.) Images need to be approved to appear in the feeds
3.) There's another metadata tag I need to add to posts. 

Any help would be appreciated. 

For additional context: Here's a screenshot of my post with the `cover_image`.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/3ruqexxmunuefw970xko.png)


Here's a screenshot of my post in the feed:

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/16hm4ua5stk2ezto0hy1.png)
CSS Conical Gradients - Awesome Button Effects!
Tags: css, tutorial, webdev, html
Published: 2019-08-26 22:15:23

Did you know that CSS now (largely -- [see support](https://caniuse.com/#feat=css-conic-gradients)) has support for conical gradients in addition to the standard linear and radial?  If this if your first time hearing the word conical, then this tutorial is for you! Visual learners: Watch the youtube video tutorial ([subscribe to the channel!](http://www.youtube.com/c/FollowAndrew?sub_confirmation=1)):
{% youtube XMEX9_HvW2k %}


##What Are Conical Gradients?
Canonical gradients get their name from the 'cone' shape that they visually create.  A picture is worth a thousand words here.  Canonical gradients wrap around the outer bounds of the area, instead of slicing through the center like so:
![Conic Gradient Visual](https://thepracticaldev.s3.amazonaws.com/i/os23h6qafok8d62uz11m.png)

##Conical Gradient Syntax
You can create conical gradients with a similar syntax to linear gradients like so:
```css
background: conic-gradient(red, orange, yellow, green, blue);
```

##Units of Measure
One important thing to keep in mind, is that because Conical gradients use an ‘angle’ as values, we have atypical css unit types that we can leverage.  Here is a list of the available units you can use with these gradients:

- **deg** - Degrees (360 degrees)
- **grad** - Gradians (400 gradians)
- **rad** - Radians (2π radians)
- **turn** - Turns (1 turn)
- **%** - Percentage (100%)

##A Few Samples:
Note, if your browser doesn’t support conic gradients, (cough Firefox) you can use [this awesome polyfill.](https://leaverou.github.io/conic-gradient/)

### Sunburst Background via Repeating Gradient
```css
div{
background: #0ac repeating-conic-gradient(hsla(0,0%,100%,.2) 0 15deg, hsla(0,0%,100%,0) 0 30deg);
}
```
![Sunburst](https://thepracticaldev.s3.amazonaws.com/i/wooiz6pqxhgo84nhw28g.png)

### Pie Charts Anyone?
note these aren't great for accessibility

```css
div{
    background: conic-gradient(
     red 48deg, green 48deg 195deg, blue 195deg);
    border-radius: 50%
}
```
![Pie Chart](https://thepracticaldev.s3.amazonaws.com/i/1fiaq5ryvjrtgf82sx62.png)

### Checkerboard Pattern (fancy 'transparent' layer effect)

```css
div{
    background:
    conic-gradient(#fff 0.25turn, #bbb 0.25turn 0.5turn, #fff 0.5turn 0.75turn, #bbb 0.75turn)
    top left / 10% 10% repeat;
    outline: 1px solid;
}
```
![Checkerboard](https://thepracticaldev.s3.amazonaws.com/i/xxh8ktoa7fo3g5h0osrd.png)

### True "Cone"-ic Gradient

```css
#five{
    background: conic-gradient(from -28deg, white,black 180deg,white);
    border-radius:50%;
    transition:all .5s;
    transform:rotate(0deg);
}
```
![Conic](https://thepracticaldev.s3.amazonaws.com/i/t07e13nrj2vt7pswhcka.png)

### Fancy Pants Button (Ana Tudors)

{% codepen https://codepen.io/thebabydino/pen/qdPRpN default-tab=js,result %}
PSL 96 Stylesheets
Tags: help, webdev
Published: 2019-08-26 21:57:48

I was reading about the various ways in which the first stylesheet proposals came into being. One really stood out to me, PSL 96 which had statements and other logical features. I couldn't find much on the internet about this. Does anyone happen to know what the syntax looked like?

[must read if you like history](https://css-tricks.com/look-back-history-css/)
New Challenge: Fullstacking with React Native
Tags: reactnative, javascript, mongodb, koajs
Published: 2019-08-26 21:27:19

So, I really want to work at [@fotoncompany](https://dev.to/fotoncompany) and accepted a *challenging* challenge to make an application using full-stack skills.  
I've participated in an acceleration program at [@codenation](https://twitter.com/codenationdev) and learned `Golang + ReactJS` as well as `Redux`, `Git`, testing and team development. However for this project I'll need to know several other tools and technologies such as `React-Native` *(at least it's pretty similar to React, right?)*, `KoaJS`, `MongoDB` and more stuff I yet have to find out I'll use.  
I'll also have to set up a developing environment for `Android` *(it seems I kinda need iPhone and/or Mac to develop to iOS, but that's details)*  
While learning all these interesting topics, I'll share my difficulties and some step-by-step instructions on how to beat them.  
**Stay tuned!**
zanzibar
Published: 2019-08-26 21:23:22

Zanzibar is a city that operates to a large extent independently without government control. It is surrounded by a lot of beautiful islands. It offers a lot of countries either visa free or visa on arrival.
There are various mode of transportation available to commute round the city, places that I call a must to visit includes: Zanzibar island, market in stone town, caves, jozani forest, seeweed center. These are beautiful places and I enjoyed every bit of my moment in Zanzibar. I would recommend Zanzibar as a tourist city for anyone with a flair for nature. for more interesting attractions in Zanzibar, visit https://timbu.com/search?query=zanzibar
Pigeon Organizer Lab
Tags: ruby
Published: 2019-08-26 21:07:41

## Problem

I'm given a hash of information and I need to rearrange them into a new hash sorted in a different way. 

To go from this:
```ruby
pigeon_data = {
  :color => {
    :purple => ["Theo", "Peter Jr.", "Lucky"],
    :grey => ["Theo", "Peter Jr.", "Ms. K"],
    :white => ["Queenie", "Andrew", "Ms. K", "Alex"],
    :brown => ["Queenie", "Alex"]
  },
  :gender => {
    :male => ["Alex", "Theo", "Peter Jr.", "Andrew", "Lucky"],
    :female => ["Queenie", "Ms. K"]
  },
  :lives => {
    "Subway" => ["Theo", "Queenie"],
    "Central Park" => ["Alex", "Ms. K", "Lucky"],
    "Library" => ["Peter Jr."],
    "City Hall" => ["Andrew"]
  }
}
```
To this:
```ruby
pigeon_list = {
  "Theo" => {
    :color => ["purple", "grey"],
    :gender => ["male"],
    :lives => ["Subway"]
  },
  "Peter Jr." => {
    :color => ["purple", "grey"],
    :gender => ["male"],
    :lives => ["Library"]
  },
  "Lucky" => {
    :color => ["purple"],
    :gender => ["male"],
    :lives => ["Central Park"]
  },
  "Ms. K" => {
    :color => ["grey", "white"],
    :gender => ["female"],
    :lives => ["Central Park"]
  },
  "Queenie" => {
    :color => ["white", "brown"],
    :gender => ["female"],
    :lives => ["Subway"]
  },
  "Andrew" => {
    :color => ["white"],
    :gender => ["male"],
    :lives => ["City Hall"]
  },
  "Alex" => {
    :color => ["white", "brown"],
    :gender => ["male"],
    :lives => ["Central Park"]
  }
}
```

## What I Learned

While this one was challenging, I learned the most from this lab so far. 

1. How to iterate through a hash using `.each` and assigning the keys and values different names. 

2. I found that creating a new hash required to check to see if it exists which I found interesting. What I though I could do in one line, I had to do in three. I later found out I could do it in a single line using `pigeon_list[:name] || = {}` but I'm not sure how to use it yet.

3. I re-learned how to change something to a string using `.to_s`

## Final Iteration

```ruby
def nyc_pigeon_organizer(data)
  pigeon_list = {}
  data.each do |color_gender_lives, value|
    value.each do |stats, all_names|
      all_names.each do |name|
        if pigeon_list[name] == nil
          pigeon_list[name] = {}
        end
        if pigeon_list[name][color_gender_lives] == nil
          pigeon_list[name][color_gender_lives] = []
        end
        pigeon_list[name][color_gender_lives].push(stats.to_s)
      end
    end 
  end
  pigeon_list
end
```
Resolving "type or namespace not found" in .NET
Tags: net
Published: 2019-10-19 14:11:46

---
title: Resolving "type or namespace not found" in .NET
published: true
tags: NET
canonical_url:  https://www.code4it.dev/blog/dotnet-type-or-namespace-not-found
cover_image: https://res.cloudinary.com/bellons/image/upload/t_dev-to/Code4IT/Covers/type-not-found.jpg
---

Something strange happened today.

I've developed a Class Library in .NET Framework and I tested it with the related test library.

So I've integrated the library into another project. Everything was fine, I used that library without problems. 
But, all of a sudden:

_Error CS0246: The type or namespace name 'XX' could not be found (are you missing a using directive or an assembly reference?)._

__What?!?__ I've been using it for the whole week. I've tested it. I've added the reference, and the Intellisense works as well.

C'mon, the class is here!

Clean the solution... nothing happens.

Close Visual Studio... still nothing.

Have a coffee... well, better now.

Suddenly, a doubt: _what if I've created it in .NET Core instead of .NET Framework?_

And, obviously... no, it wasn't that.

But I was close: the Class Library was in _.NET Framework 4.7.2_ but the application was in _.NET Framework 4.7.1_. __It was the patch version!__

So, I just downgraded the class library version through Visual Studio, and everything went well again.

You can find the version in the Properties screen of the project (right-click on the project in the Solution Explorer or _Alt+Enter_), in the _Application_ tab, then under the _Target framework_ field.

![.NET version selection on Visual Studio 2019](https://res.cloudinary.com/bellons/image/upload/Code4IT/TypeOrNamespace%20not%20found/dotnet-version-selector.png)

So, the lesson is: _know your enemy_, and check for the slight details.
Self Hosted Gitlab Continuous Deployment to Netlify
Tags: tutorial, devops, git, react
Published: 2019-08-26 20:23:45

If you haven't yet checkout out [Netlify](https://netlify.com), you definitely should!

While Netlify has direct integration with Github, Bitbucket and the managed Gitlab service, things get confusing if you have your own Gitlab instance. This post is to help out anyone wanting to write a Gitlab pipeline to deploy their website directly to Netlify from Gitlab's CI/CD tool.

### Step 1: Get your Netlify Personal Access
Head over to [User Settings > Applications > Personal Access Token](https://app.netlify.com/user/applications#personal-access-tokens) and generate a new access token. You put "Gitlab CD" as the description of your token. Once generated, make sure you copy and keep the access token in a file or in an active editor window.

### Step 2: Get your Netlify Site API ID
Next, go to your site's setting page in Netlify Dashboard can copy the value of `API ID`.

### Step 3: Add the variables to your Gitlab CI/CD settings
Open the repo on your self-hosted Gitlab instance and go to Settings > CI/CD. 
* Add the access token from step 1 under the variable name `NETLIFY_AUTH_TOKEN`
* Add the API ID from step 2 under the variable name `NETLIFY_SITE_ID`.

<img src="https://i.ibb.co/WBL0zsb/Screenshot-2019-08-27-at-1-39-36-AM.png" alt="Screenshot-2019-08-27-at-1-39-36-AM" border="0">


### Step 4: Add a `.gitlab-ci.yml` file to your repo
Add the Gitlab CI file to your repo. Following is a basic template to start you off:

```yml
stages:
  - deploy

deploy:
  stage: deploy
  environment:
    name: production
    url: https://your.website.com
  only:
    - master
  script:
    - npm i
    # your build command
    - npm run build
    - npx netlify-cli deploy --site $NETLIFY_SITE_ID --auth $NETLIFY_AUTH_TOKEN --prod
```

### Step 5: Add a file named `netlify.toml` to your repo

This file contains the directory which needs to be pushed to Netlify (the directory where your project is built). It's usually named `build` or `dist`.

```toml
[build]
  publish = "build"
```

That's it! Now just commit these changes and push to `master` and see your website get deployed on Netlify :)
Minimal list drag and drop library, Should I re-implement to be a custom hook?
Tags: react
Published: 2019-08-26 20:11:18

Hi I recently made this small library for making any list of React components to be draggable with minimal setup https://github.com/juanto121/Droplite but now I'm wondering if it would be more usable if it were to be implemented as a custom hook. Please let me know, I'm new to react's component library community.
I just did my first guest podcast and I'm giving away a free study course for AWS Certification!
Tags: aws, career, beginners, fullstack
Published: 2019-08-26 20:02:17

---
title: I just did my first guest podcast and I'm giving away a free study course for AWS Certification!
published: true
tags: aws, careers, beginners, fullstack
description:
---

I just did a podcast with Skill Pathway on how important it is to add Cloud Computing to your list of skills so you can increase your chances of getting a job as a Full Stack Developer in the web-dev industry.


So in the spirit of sharing, I'm giving away access to my AWS Certified Cloud Practitioner Study Course. It normally cost $35 USD but it's free for the first 100 people and all you have to do is leave a comment in the Skill Pathway post telling Matthew what's your top tech skill: 

{% link https://dev.to/skill_pathway/a-ceo-s-1-tip-on-how-stand-out-as-a-new-full-stack-developer-in-a-competitive-market-6h2 %}

You don't get anything for commenting here but you're welcomed to do so.
Once you leave a comment, then Matthew will be able to send you a chat message through Dev.to with the code that will get you free access.
About Stuart Hankin
Tags: stuarthankin, stuarthankinhankinhomes
Published: 2019-08-26 19:56:08

Stuart Hankin Hankin Homes grew up in a suburb outside Philadelphia. Stuart Hankin has a Bachelor's Degree in Operations and Information Engineering from Cornell University, which he achieved in just 3 years. In 2010, Stuart Hankin started buying and rehabbing distressed Real Estate in South Florida. In 2016 Stuart Hankin began to purchase both residential and commercial land. Stuart Hankin spent the next 3 years learning the most efficient way to build new construction. In 2019, Stuart Hankin Hankin Homes completed his first 5 affordable new construction projects, which were a great success. Stuart Hankin is actively involved in philanthropic activities, from being involved in his local Chabad, to volunteering his time as a tutor for kids in the Kids Sanctuary program. Stuart Hankin married Britney Linsky in 2014, and in 2016 they welcomed their first child, Harry Hankin, named after Stuart's grandfather. Stuart Hankin Hankin Homes inherited his entrepreneurial spirit from his grandfather, the original Harry Hankin. Currently, Stuart Hankin lives in Palm Beach Gardens, Florida, and spends his free time with his family, and developing new business concepts.
Introducing Feelsbot: Artificially Intelligent & Emotional
Tags: artificalintelligence, machinelearning
Published: 2019-08-26 19:18:43

---
title: Introducing Feelsbot: Artificially Intelligent & Emotional
published: true
description: Feelsbot tries to understand how humans are feeling by reading their tweets.
tags: artificalintelligence, machinelearning
---

Hello, internet! This is [Feelsbot](https://www.feelsbot.me/). Feelsbot tries to understand how humans are feeling by reading their tweets. Feelsbot can analyze Tweets of any geographical location or any public Twitter profile.

![Gif of Feelsbot working](https://thepracticaldev.s3.amazonaws.com/i/jhfrck232gln92bg7wkt.gif)


Feelsbot uses artificial intelligence to analyze emotional sentiment in Tweets. Play around with Feelsbot and let us know what you think. Did Feelsbot surprise you in any way?

Stay tuned for a post tomorrow about what machine learning is and how Feelsbot is using it.
What's the nicest thing anyone's said to you, as a developer?
Tags: discuss, culture, mentalhealth, workplace
Published: 2019-08-26 18:48:12

---
title: What's the nicest thing anyone's said to you, as a developer?
published: true
description: 
tags: discuss, culture, mentalhealth, workplace
cover_image: https://thepracticaldev.s3.amazonaws.com/i/mecu7516es0owjk9yser.jpg
---

I'm not talking about the best advice you've been given for your career, or something you wish you'd paid attention to when you were starting out. It doesn't have to be a direct compliment.

Something just plain nice[^1], something that made you feel good.

[^1]: cover photo by Alex Knight on Unsplash