teleren/devto huggingface dataset:
How to checkout github pull requests locally like Pro

Tags: github, git, beginners, tutorial
Published: 2020-10-01 18:57:16

If you work with the repositories hosted on Github , you have to deal with lot of Pull requests daily generally, and the process to checkout the PR's locally in your machine is quite not easy, you have to see the PR's id and also the branch name.

```bash
git fetch origin pull/ID/head:BRANCHNAME
```

And if the PR is in upstream repository, first you need to add that particular user as remote in your local copy of the project and then pull the particular branch of the contributor. For example

```bash
git remote add fayem git@github.com:fayepal/itsopensource.git
git checkout -b fayem fayepal/blog-docker-vm
```

As we see its quite long process and you will have lot of remote added in your repository as well.

To solve this there is a awesome [git alias](https://gist.github.com/gnarf/5406589) by gnarf:

```bash
[alias]
  pr  = "!f() { git fetch -fu ${2:-$(git remote |grep ^upstream || echo origin)} refs/pull/$1/head:pr/$1 && git checkout pr/$1; }; f"
  pr-clean = "!git for-each-ref refs/heads/pr/* --format='%(refname)' | while read ref ; do branch=${ref#refs/heads/} ; git branch -D $branch ; done"
```


Either you can add them directly in your `.gitconfig` file or by doing so:


```bash
git config --global alias.pr '!f() { git fetch -fu ${2:-$(git remote |grep ^upstream || echo origin)} refs/pull/$1/head:pr/$1 && git checkout pr/$1; }; f'
git config --global alias.pr-clean '!git for-each-ref refs/heads/pr/* --format="%(refname)" | while read ref ; do branch=${ref#refs/heads/} ; git branch -D $branch ; done'
```

Now you simply do `git pr x` and it will do the magic for you:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/8epzbjljjo7t49wiaf3h.jpg)

Cheers
Hacer === Function // Que hago === Data
Published: 2020-10-01 18:57:03

Me gusta la idea de que mis funciones se conceptualizan de manera general para que puedan ser usadas en diferentes casos especificos. Resulta que el uso que le doy a algo que tiene nombre, es solo un uso que puede ser un termino diferente para otra persona. La capacidad de desconceptualizar el termino con la acción, libera a la acción de ser reutilizada en más maneras, porque ahora ya no tengo que HacerX(), HacerY(), HacerZ(), solo tengo que Hacer(Algo).
Cross compile Crystal to aarch64
Tags: crystal
Published: 2020-10-01 18:53:33

Here's an example of how to cross compile a crystal app on a host machine and then transfering it to the target machine (in this case an Ubuntu aarch64/arm64) and compile the last bits there:

```bash
#!/bin/bash -eu

srcfile=$1
target=$2

export CFLAGS="-fPIC"
buildcmd=$(crystal build --cross-compile --target=aarch64-unknown-linux-gnu --release $srcfile)

# Upload the object file to the aarch64 machine
scp "$(basename $srcfile .cr).o" "$target":.
rm "$(basename $srcfile .cr).o"

# SSH to the target machine
ssh "$target" << EOF
# install dependencies
sudo apt-get install -y clang libssl-dev libpcre3-dev libgc-dev libevent-dev zlib1g-dev

# download and compile crystal's sigfault library
wget https://raw.githubusercontent.com/crystal-lang/crystal/master/src/ext/sigfault.c
cc -c -o sigfault.o sigfault.c
ar -rcs libcrystal.a sigfault.o
sudo mkdir -p /usr/share/crystal/src/ext
sudo cp libcrystal.a /usr/share/crystal/src/ext/

# compile the object file with the command crystal build --cross-compile gave us
$buildcmd
EOF
Hacktober backfires on OSS
Tags: hacktoberfest
Published: 2020-10-01 18:53:05

# Hacktober Fast🍻

Looks like the lure of the free tshirt is causing more headaches than help to the open source community

A new twitter account [@shitoberfest]
(https://twitter.com/shitoberfest)

is documenting collecting some _"fun"_ contributions.

## Tip

### If you're participating, try to contribute in a helpful way.

[how-to-contribute](http://opensource.guide/how-to-contribute/)


## Don't be this guy

(here's a couple fun ones...)

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/d4jdqdstjghaesqmlhyr.jpg)

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/gciokwjt9aci4vy1v7j0.jpg)

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/vbb1syxartlmozr1r1sx.jpg)



[cover image](https://twitter.com/ben_a_adams/status/1311704712538923009)
Contribute to BitcartCC this Hacktoberfest 
Tags: hacktoberfest, showdev, opensource, python
Published: 2020-10-01 18:50:24

BitcartCC is an open-source self-hosted all-in-one cryptocurrency solution.

It can be used as an [SDK](https://sdk.bitcartcc.com) for custom apps, via [Merchants API](https://api.bitcartcc.com), via [ready admin panel](https://admin.bitcartcc.com), [store](https://store.bitcartcc.com) or ready integrations.

![photo_2019-08-09_10-00-20](https://dev-to-uploads.s3.amazonaws.com/i/z24afl62l88qav9qyzn4.jpg)
 
Learn more at https://bitcartcc.com

Hacktoberfest has started and we have prepared lots of issue descriptions for it!

## Not sure how to start? Here are some steps:

1. Try to understand what we are trying to solve and how BitcartCC works. Documentation is published here https://docs.bitcartcc.com

2. Go through the [CONTRIBUTING](https://github.com/bitcartcc/bitcart/blob/master/CONTRIBUTING.md) guide:
    Try to run BitcartCC from the source.

3. Find an interesting issue to solve.
    Go through the open issues listed [here](https://github.com/bitcartcc/bitcart/issues/133). You can choose anyone from an existing open issue or propose/create a new issue if you feel something is missing and want to improve. The first-timer issues are tagged with `good-first-issue` labels. Such issues are simpler and comparatively easy to fix. So you can start with that.
    Feel free to join BitcartCC Telegram group at https://t.me/bitcartcc and raise questions, discuss anything.

Happy hacking 🚀
A View From Start To Finish - Building SaaS #60
Tags: python, django, saas
Published: 2020-10-01 18:12:27

{% youtube nLG017x0yys %}

In this episode, I created a view to add students from beginning to the end.  I used Error Driven Development to guide what I needed to do next to make the view, then wrote tests, and finished it all off by writing the template code.

At the start of the episode, I gave a quick overview of the models in my application and which models I planned to focus on for the stream.

We worked on a view to add students.  I did this using a technique that I called *Error Driven Development*.  With this strategy, I started with what I wanted and followed the error messages to drive to what I needed to write.  Django's error messages are good enough to show what was needed for each step.

After creating a view that didn't error anymore, I filled in some tests to prove that the view behaved in the way I wanted.

Finally, I wrote the template that provides the proper data for the newly created view.

Once the template was complete, I did one manual end-to-end test to confirm that the template and view worked together.  I verified in the Django admin that the view created a new student.

This article first appeared on [mattlayman.com](https://www.mattlayman.com/building-saas/view-from-start-to-finish/).
Modern JavaScript Essentials
Tags: webdev, javascript, programming, code
Published: 2020-10-01 18:04:54

This article consists of notes taken in a practical introduction to the native modern JavaScript language by [Samer Buna](https://www.linkedin.com/in/samerbuna/). This introduction covered topics such as objects, functions, scopes, promises, modules, and APIs.

Read more about it here: https://weblog.tiagoperes.eu/modern-javascript-essentials/
Daily Challenge #295 - Sort Leaderboards
Tags: challenge
Published: 2020-10-01 18:01:59

---
title: Daily Challenge #295 - Sort Leaderboards
published: true
series: Daily Challenge
description: Use information from an array to sort the leaderboard. 
tags: challenge
//cover_image: https://direct_url_to_image.jpg
---
In this challenge, you'll be given a leaderboard in the form of an array, as well as a list of strings. Using the information in the list, sort the leaderboard. 

###Example
*array:*
```
['John',
 'Brian',
 'Jim',
 'Dave',
 'Fred']
```
*list:*
`['Dave +1', 'Fred +4', 'Brian -1']`

The steps for our example would be:
```
# Dave up 1
['John',
 'Brian',
 'Dave',
 'Jim',
 'Fred']
# Fred up 4
['Fred',
 'John',
 'Brian',
 'Dave',
 'Jim']
# Brian down 1
['Fred',
 'John',
 'Dave',
 'Brian',
 'Jim']
```
Then, we return the completed leaderboard:
```
['Fred',
 'John',
 'Dave',
 'Brian',
 'Jim']
```

Strings will never ask you to move a name higher or lower than possible. The strings in the list will always be a name in the leaderboard, followed by a space and a positive or negative number.

###Tests
`leaderboardSort(['John', 'Brian', 'Jim', 'Dave', 'Fred'], ['Dave +1', 'Fred +4', 'Brian -1'])`
`leaderboardSort(['Bob', 'Larry', 'Kevin', 'Jack', 'Max'], ['Max +3', 'Kevin -1', 'Kevin +3'])`


Good luck!

***
_This [challenge](https://www.codewars.com/kata/5f6d120d40b1c900327b7e22) comes from topping on CodeWars. Thank you to [CodeWars](<https://codewars.com/>), who has licensed redistribution of this challenge under the [2-Clause BSD License](<https://opensource.org/licenses/BSD-2-Clause>)!_

_Want to propose a challenge idea for a future post?  Email **yo+challenge@dev.to** with your suggestions!_
What's the order of execution?
Tags: javascript, quiz, webdev
Published: 2020-10-01 17:41:38

```
setTimeout(() => console.log('1'), 0);

Promise.resolve().then(() => console.log('2'));

console.log('3');
```

---

**Thanks for reading 💙**  
Follow **@codedrops.tech** for daily posts.  
[Instagram](https://www.instagram.com/codedrops.tech/) ● [Twitter](https://twitter.com/codedrops_tech) ● [Facebook](https://www.facebook.com/codedrops.tech/)

Micro-Learning ● Web Development ● Javascript ● MERN stack ● Javascript  
**[codedrops.tech](https://www.codedrops.tech/)**
Jupyter Notebooks in GitHub Codespaces
Tags: github
Published: 2020-10-01 17:40:04

Tried out the default Microsoft custom python3-anaconda GitHub Codespace today.  Very easy to set up and use.  Really like the 'show (notebook) variables' option in "locally" connected Jupyter notebook.  There is also the ability to connect to remote Jupyter server using the notebook interface in Codespaces.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/xm8bkn7j9qp9jhj2vqsu.png)


Had to use 'sudo' to update 'pip' in order to install the matplotlib library and the Jupyter extensions, but, other than than it just worked directly from the sample code in the [example MSFT repo](https://github.com/microsoft/vscode-dev-containers/tree/master/containers) `.devcontainer` files for Python3 for Codespaces.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/f4npb6tqeve28klcos69.png)

This is so handy, I can see myself using this set of functionality frequently!

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/e5hve0gu5vfrj93c2jt9.png)
You Should Know Top 8 Python Libraries in 2020
Tags: top, pythonlibraries, python, codenewbie
Published: 2020-10-01 17:39:22

You Should Know Top 8 Python Libraries in 2020:
.
- Numpy
- TensorFlow
- Theano
- Scikit Learn
- SciPy
- PyTorch
- Keras
- Pandas
.

- Explained By @DDSRY21
Microsoft Reactor: Workshop de AKS com Virtual Nodes e AKS Com GitHub Actions
Tags: azure, kubernetes, docker, github
Published: 2020-10-13 03:12:41

---
title: Microsoft Reactor: Workshop de AKS com Virtual Nodes e AKS Com GitHub Actions
published: true
date: 2020-10-01 17:17:34 UTC
tags: azure,kubernetes,docker,github
canonical_url: https://blog.lsantos.dev/microsoft-reactor-workshop-de-aks-com-virtual-nodes-e-aks-com-github-actions/
cover_image: https://raw.githubusercontent.com/khaosdoctor/blog-assets/master/images/2020/10/imgpsh_mobile_save.jpg
---

No dia 29 participei de uma live sensacional do Microsoft Reactor com o grande [Caio Calado](https://www.linkedin.com/in/caiocaladoo/) como host!

Nesta live fizemos um workshop prático de como podemos criar um cluster no [Azure Kubernetes Service](https://docs.microsoft.com/azure/aks/?WT.mc_id=blog-personal-ludossan) e utilizar o poder dos Virtual Nodes para ter escalabilidade infinita, essa é a nossa primeira demonstração.

Depois, partimos para uma criação prática de um repositório no GitHub para utilizar o GitHub Actions de forma a podermos criar e fazer os deploys de aplicações completas para o [AKS](https://docs.microsoft.com/azure/aks/?WT.mc_id=blog-personal-ludossan) sem precisar sequer tocar nelas

Tudo isso você encontra de forma gratuita no vídeo abaixo!

<iframe width="612" height="344" src="https://www.youtube.com/embed/qB_B5mkDpIA?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

Não esqueça de curtir e compartilhar para que outras pessoas também possam ter acesso a este conteúdo! Se inscreva na newsletter aqui embaixo e deixe suas impressões nos comentários. Todos os feedbacks são bem vindos 🤓

## Links comentados

- [Link para o repositório de exemplo](https://github.com/khaosdoctor/aks-gh-actions-demo/)
First time participating in the Hacktoberfest event
Tags: hacktoberfest, writing, opensource
Published: 2020-10-01 17:14:57

# Hello World!
So this is my first post on dev.to yeay! I finally write on this cool platform.
I will tell you about my experience for the first time participating in the hacktoberfest event, especially hacktoberfest 2020.


### The beginning
I know the hacktoberfest event has actually been a long time ago, but at that time I was not interested in participating in it. until finally I saw my friends' posts on their social media about hacktoberfest 2020, at first I was still not interested in participating in it but gradually I was curious and asked myself 'hmm..what does it feel like to join this event, it seems interesting' and not long after that I finally opened the hacktoberfest 2020 website and immediately registered with my Github account and started reading the terms.


### Create a project
After I read the terms, there were all the pull requests (to anyone's repository) that could be counted. Finally, I thought about making a small project, but I was confused about what to do, the notification on my cellphone appeared and I saw that it was the teacher's job. subject 'OBJECT-ORIENTED PROGRAMMING' (fyi, I am a student in a vocational high school and my major is software engineering), its task is to create a Java Gui program for food ordering.
'Emm..okey, I can make this as a project for hactoberfest' because from there I can complete my task and fulfill the hacktoberfest pull request target.
> as the saying goes, **_"once rowing two and three islands is exceeded"_**


### Pull request
After making a project on Github I thought that if I was the only one contributing it wasn't interesting, I also asked my friend to help with this task because he was in my class and got the same assignment.
After a few hours he made a pull request to my repo and I accepted the pull request, until finally I did several pull requests and yes the project was finished.

### The final word
Maybe it's a bit of my experience following the hacktoberfest2020 event, overall I'm happy to join this event because from there I can collaborate with my friends and make contributions.
🎨 CSS developer roadmap
Tags: html, css, career, beginners
Published: 2020-10-01 17:08:28

Here is [CSS developer roadmap](https://infinite.education/expertise/CSS_Guru)
Useful for experienced users: to check all skills

Give feedback please what to add to roadmap!

PS project page: https://www.facebook.com/InfEducation

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/053izxmi0t6ywetireql.png)
Process still running even connection gets killed
Published: 2020-10-01 17:06:46

I used requests to do mass database insertions which take longer than the proxy's time limit. As a result, I had to make multiple requests to finish it, and this made mistaken duplicate insertions even after the code check and block the duplicate data, cause they are basically inserted at the same time.
This is because even the request connection got killed, the process it started is still running. And the multiple requests I made just  started parallel processes
Why I learnt HTML for a whole year
Tags: html, codenewbie, 100daysofcode, webdev
Published: 2020-10-01 17:02:08

Hi everyone,
My name is Gladness but I am called Burger on Twitter.
Straight to how I learnt HTML for a whole year.

I started HTML as a pure newbie, I knew nothing and I had no one to put me through. I made my way into Coding all by myself because there was nobody in my environment that codes not even in school not even an uncle or teacher or neighbor, nobody.
Worst of all I had no mobile device to practice it nor a laptop but I seriously wanted to learn how to code.
I started Coding at the age of 13years, it was tough then. But one fateful day my class mate came over to me and discussed that he would love to also learn how to code. We talked this through until he told me his Dad was a Software Engineer before he died. On hearing his death, I was very sad because I thought I had met someone to teach me to code. I asked my friend if he had books he uses and he said he has a lot of them. I was happy and I persuaded my friend to bring me one of his books. And he brought books that talked about "HTML, Dhtml, Javascript" I started with HTML and that was how I started my Dev journey.

Why did I learn HTML for a year?
- I didn't believe in myself
- There wasn't device for 
  constant practice
- I wasn't determined then 
  that I could make it
- I had problem with my 
  parents discouraging me now 
  and then.
- I wasn't devoted to what I 
  was learning.
- While learning I got to a 
  hard point I didn't 
  understand, I wasn't 
  persistent enough to learn 
  and understand.
- I gave up at some point.

All the points above made me to learn HTML that could be learnt thoroughly for a week in a year. It's so sad and I'm bad about it but I am glad that I am getting better at it and I'm almost through with everything related to CSS moving on to Javascript. It has been much fun for me. Now I am 17years still enjoying my code journey as a kid.

If you love this article kindly drop a like, drop a positive comment or motivation and don't forget to follow me as I'm gonna be writing articles on HTML and CSS, I know there are many articles and blogs that discussed it but another way of explanation could make use understand nwhat you thought you understood. I look forward to impacting in your lives.
Happy Coding 👩‍💻👩‍💻
10 layman's Simple advices to beginners
Tags: beginners, firstyearincode
Published: 2020-10-01 17:00:55

**Front-end**
(1) It is not an "Id" but "name" that is fetched by  database in the html form.

(2) Codepen.io is the easiest way to play with codes. Go get the inspiration there.

(3) No system is faster than using a service worker resource cache. Tools like css js html on the client side are blazing quick results.

(4) Client-side validation is no security . Just saves time of client. Use server validation of forms.

(5) Use gtmetrix.com or similar website to perform performance tests and suggestions.

**Back-end**
(6) Learn a language that is not a framework. Depending on the framework, it's like you can read, but don't know how to write. The framework loop hole will be the loop in your app. Frameworks have a short life span, but your career is not a short one.

(7) The most critical security measures are csrf, token, server validation, etc. You should learn how to apply it in any language.

(8) There is no good code. There's always a simpler way to code. So, no matter what you're coding, feel content.

(9) Learn go and JavaScript.

(10) Code in such a way that your server has not to run so many queries. Learn to implement Function as a service.

**Bonus: The Truth**

(1) Without learning linux, you are half cooked developer. 90% of servers in production are linux. Atleast, you should have idea.

(2) Devops is easier than both front-end and back-end development.

(3) Spend more time on dev.to than Facebook or Instagram.

(4) Scan GitHub for open-source or awesomeopensource.com

(5) Create your own tools. For example: I created manish.imfast.io for getting best results on Google from my favourite sites.

[ PLEASE GIVE YOUR SIMPLE ADVICE IN COMMENTBOX]

**Please visit my profile for more interesting articles**


######***IMP REQUEST:***

###### You are most welcome to join my team 
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/3qhbvg5fsrh3nt7anh36.png)

[ Click here for joining my team ]
(https://forms.gle/pSCALuEWHus3pg9F6).

###### *Also you are most welcome to join OPEN SOURCE INTELLIGENT SYSTEM (OSINT) if you can help in open source project regarding safeguarding humans from various diseases like CORONA outbreak*
######https://github.com/Manishfoodtechs/OSINTHRH/wiki

Contact email: Manishfoodtechs@gmail.com. 

If you have any problem, our team is also engaged in professional consultancy and delivery.

![](https://media2.giphy.com/media/oNrPzIy3OhHm7zrvA3/source.gif)

Imagecredit: pixabay
No Country for Old Developers
Tags: inclusion, webdev, programming, technology
Published: 2020-10-11 17:55:15

---
title: No Country for Old Developers
published: true
date: 2020-10-01 16:55:09 UTC
tags: inclusion,webdevelopment,programming,technology
canonical_url: https://medium.com/swlh/no-country-for-old-developers-44a55dd93778
---

[![](https://cdn-images-1.medium.com/max/1920/1*2pg13i75XAAuKQM7LEiiyw.jpeg)](https://medium.com/swlh/no-country-for-old-developers-44a55dd93778?source=rss-8f1b0c5dd7cc------2)

The truth behind ageism in the tech industry-and strategies for overcoming it.

[Continue reading on The Startup »](https://medium.com/swlh/no-country-for-old-developers-44a55dd93778?source=rss-8f1b0c5dd7cc------2)
Need help with NEXT.CONFIG.JS [see attached image]
Published: 2020-10-01 16:40:50

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/uggj42is0rpup9gututc.png)

Can some one help me with this piece of code, I just want to add some webpack configurations but i'm not a pro at all.

I added context in comments. Also i added the github link in the comments sections

Thanks in advance
Your resident noob