teleren/devto huggingface dataset:
Announcing playCTF - An open source Jeopardy style CTF creation and management platform!
Published: 2022-06-28 18:55:40

CTFs are much more than just an event or a competition, they are an adventure. And being able to host them on a great open source platform with ease adds to the fun.

SDSLabs is proud to announce the release of playCTF, a Jeopardy-style CTF challenge deployment and management platform.

Its intuitive and user-friendly deployment interface enables anyone to set up a CTF competition in a couple of minutes.

playCTF incorporates BEAST, our CTF creation platform, which provides container-based isolation of each challenge.

Check it out on https://playctf.sdslabs.co.

Experience playCTF on the playCTF playground (https://playground-playctf.sdslabs.co), or have a peek at the source code (https://github.com/sdslabs/playctf).

Also, check out the Beast GitHub repository (https://github.com/sdslabs/beast) and the 
Beast User Documentation (https://beast.sdslabs.co),

Give it a chance, and Beast will surely live up to it's name for you! 

Made with 💖 by SDSLabs

Intrigued and wanna chat more with the team behind it?

(https://chat.sdslabs.co) and our Discord (https://discord.gg/dXkVEgTPu9) is open to all visitors and questions 😉

[View Video](https://drive.google.com/file/d/1Z8C7RDjafCfrFQoVRpO7B2ydiHOPzDRT/view)
💧FLUTTER TIP💧
Tags: flutter, dart, programming, beginners
Published: 2022-06-28 18:52:14


You don't have to type every widget's full property name. All you need is the first letter of every word.
Note that capitalization matters.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/25so0zwg1s92i1rbn9ug.jpg)
Git Rebase got you conflicted? Here's what you can do.
Tags: github, git, versioncontrol
Published: 2022-06-28 18:49:52

Let's say you're working with feature branches. I know Trunk based development is the way to go, but hear me out. If your team is using git flow, this will help you get out of a sticky situation.

If two people are collaborating on the same feature branch, and one person rebases the branch with main/master and pushes to origin, then the other person will face a load of conflicts when pulling the branch from origin (because of the new rebased commits). Here's how you can refresh your local branch completely:

1. 𝐠𝐢𝐭 𝐟𝐞𝐭𝐜𝐡 𝐨𝐫𝐢𝐠𝐢𝐧 𝐭𝐡𝐞-𝐛𝐫𝐚𝐧𝐜𝐡 (fetch branch from origin)
2. 𝐠𝐢𝐭 𝐫𝐞𝐬𝐞𝐭 --𝐡𝐚𝐫𝐝 𝐨𝐫𝐢𝐠𝐢𝐧/𝐭𝐡𝐞-𝐛𝐫𝐚𝐧𝐜𝐡 (reset local branch and point to origin)

This will update your local branch with the one in the remote. However, if you already made some changes in your own local branch and the other teammate has rebased it, here's what you can do

Scenario A -> If you already committed the changes, in that case you can just do this:
1. 𝐠𝐢𝐭 𝐟𝐞𝐭𝐜𝐡 𝐨𝐫𝐢𝐠𝐢𝐧 𝐭𝐡𝐞-𝐛𝐫𝐚𝐧𝐜𝐡 (fetch remote branch)
2. 𝐠𝐢𝐭 𝐫𝐞𝐛𝐚𝐬𝐞 𝐨𝐫𝐢𝐠𝐢𝐧/𝐭𝐡𝐞-𝐛𝐫𝐚𝐧𝐜𝐡 (rebase your local with the remote)

Scenario B -> If you were just working on some changes but you did not commit them yet, you can simply
1. 𝐠𝐢𝐭 𝐬𝐭𝐚𝐬𝐡 (To stash your local changes)
2. follow the initial 2 steps to refresh the local branch
3. 𝐠𝐢𝐭 𝐬𝐭𝐚𝐬𝐡 𝐩𝐨𝐩 (to get your local changes back)
4. continue your work!

#gitflow #trunkbaseddevelopment #softwareengineering #softwaredevelopment #git #github #versioncontrol
Instagram Logo | Pure CSS
Tags: codepen, css, showdev, beginners
Published: 2022-06-28 18:37:52

In today’s tutorial, I finished creating a Instagram logo with CSS. Simple css code for this iconic staple. Though this is just a fun tutorial, you can practice CSS art to improve your CSS skills. CSS art has been a fun way for me to learn new properties and improve my CSS skills. I have a bunch of CSS art tutorials that are CSS inspired. You can check them out [here](https://codepen.io/rembertdesigns).

For this tutorial, all we need is some basic HTML and CSS.

{% codepen https://codepen.io/rembertdesigns/pen/xxWxLJO %}

If you liked this post, make sure to follow me on [Twitter](https://twitter.com/RembertDesigns) where I post daily about Tech related things!

https://www.buymeacoffee.com/rembertdesigns

### 🌎 Let's Connect

- [Portfolio](https://www.rembertdesigns.co/)

- [Twitter](https://twitter.com/RembertDesigns)

- [Github](https://github.com/rembertdesigns)

- [Codepen](https://codepen.io/rembertdesigns)

- [LinkedIn](https://www.linkedin.com/in/rrembert/)
Using [] or null in useState?
Tags: discuss, html, react
Published: 2022-06-28 18:34:46

In React I often debate with myself whether to use null or an empty array when making a useState, which I know later on will contain data.

Well of course this is either opinion-based, or it may be a set rule in your company. That is why after I have described my reason for almost always using null, I'd like to hear what you do?

**My reason**

Anyway, the reason I tend to go for null, is that when it comes to conditional statements in the HTML, it is much easier to simply have it look for the data to either be there or not. 

Of course, this won't ensure that a condition for it being an array is in place, but rather if you are sure the content you will put out is always guaranteed to be an array, then there is no reason to overuse conditionals.

```react
const [newArray, setNewArray] = useState(null);

return (
 <React.Fragment>
   {
     newArray && // loop...
   }
 </React.Fragment>
);
```

**Now, what do you do in your company, or do you even use states?**
Open Source (tsParticles) Helped me Finish a Years-Long Project Idea
Published: 2022-06-29 17:20:46

---
title: Open Source (tsParticles) Helped me Finish a Years-Long Project Idea
published: true
date: 2022-06-28 18:31:20 UTC
tags: 
canonical_url: https://malgasm.com/blog/513/open-source-tsparticles-helped-me-finish-a-years-long-project-idea
---

I had a simple, silly idea a few years ago: to program a robot with a function to help you feel a bit better. Before you get carried away, I’m not talking about a physical robot here – just a web page. The idea is, you would go to this web page and would ask, “am I good enough today?” The page would answer, “Yes!”

I had a clear vision for how I wanted the page to work. First, I wanted to display a button that prompted the user to ask if they were good enough today. Once the visitor pressed the button, I wanted them to have a celebratory moment, powered by some on-screen confetti.

![](https://malgasm.s3.us-west-1.amazonaws.com/aige-button.png)

In 2017, when I first had this idea, the state of confetti libraries was not as comprehensive as it is today. I searched for “javascript confetti” before writing this article, in 2022, and I was able to find several libraries – even some that are devoted exclusively to rendering confetti (tsParticles does more than just confetti). When I had searched years ago in 2017, I only found one library, and it required a rather expensive licensing fee, which I was unwilling to pay at the time. I reasoned that the cost of the confetti library was too high for the project that I had in mind, and I didn’t have the bandwidth at the time to build the effect myself. So I put the project down.

…Until 2022.

Throughout 2021 and 2022, while I was using [dictate.life](https://dictate.life) to catch up on [dev.to](https://dev.to) articles daily, I came across a library called _tsParticles_. After reading a couple of the product updates that the author would post on dev.to, I suddenly realized that I could finally finish the project.

So, I built it, and streamed it live on Twitch. And I’d like to share it with you:

[Am I Good Enough Today?](https://amigoodenough.today)

Thanks for reading! I hope you enjoy the tool and the story, and I hope it inspires you to work on your own projects! And of course, thank you to the creator of tsParticles, Matteo Bruni, and the tsParticles contributors!

tsParticles: [https://particles.js.org/](https://particles.js.org/)

Live coding this project on Twitch (NSFW): [https://www.twitch.tv/videos/1447226927](https://www.twitch.tv/videos/1447226927)
Distributed tracing enabled by default with Go agent update: version 3.16.0 for New Relic–Check it out here!
Published: 2022-06-28 18:04:28

Hi DEV community! 

I’m Daniel, the Developer Community Coordinator at New Relic, stopping by to share an update for New Relic users.

With the release of Go agent version v3.16.0, upon agent upgrade, customers will now have distributed tracing on by default. This eliminates the need to configure the agent in order to have access to distributed traces. Distributed tracing gives software teams working in modern environments an easy way to capture, visualize, and analyze traces through complex architectures, including architectures that use both monoliths and microservices.

To stay up to date on New Relic features, check out [this](url) site as we post monthly updates.

All the best,
Daniel
Google Logo | Pure CSS
Tags: codepen, css, showdev, beginners
Published: 2022-06-28 17:59:18

In today’s tutorial, I finished creating a Google logo with CSS. Simple css code for this iconic staple. Though this is just a fun tutorial, you can practice CSS art to improve your CSS skills. CSS art has been a fun way for me to learn new properties and improve my CSS skills. I have a bunch of CSS art tutorials that are CSS inspired. You can check them out [here](https://codepen.io/rembertdesigns).

For this tutorial, all we need is some basic HTML and CSS.

{% codepen https://codepen.io/rembertdesigns/pen/zYWYdvV %}

If you liked this post, make sure to follow me on [Twitter](https://twitter.com/RembertDesigns) where I post daily about Tech related things!

https://www.buymeacoffee.com/rembertdesigns

### 🌎 Let's Connect

- [Portfolio](https://www.rembertdesigns.co/)

- [Twitter](https://twitter.com/RembertDesigns)

- [Github](https://github.com/rembertdesigns)

- [Codepen](https://codepen.io/rembertdesigns)

- [LinkedIn](https://www.linkedin.com/in/rrembert/)
Gitlab Server Restore Tutorial
Published: 2022-06-28 17:51:08

This post allows you to restore Gitlab backups which were made in this post: https://dev.to/frederickollinger/gitlab-server-backup-howto-4l7c

It's required that you make a backup before you restore it.

Audience: Anyone who is actually running their own instance of Gitlab server. This person wants to ensure good backups and restore.

For this article, we'll cover only backups. This article was written with Ubuntu 20.04 with Gitlab version 15.0.0.

Just like the backup article, we will use /mnt/gitlab/backups as our backup directory. If this is different, then set the variable BACKUPDIR accordingly.

```bash
BACKUPDIR=/mnt/gitlab/backups
BACKUPFILE=`ls -t | grep _gitlab_backup.tar | head -1 | sed 's/_gitlab_backup.tar//g'`
```

For a restore to work properly, we need to change user and group ownership to git.

```bash
chown git.git ${BACKUPDIR}/*gitlab_backup.tar
```

Need to stop some services so we are not writing and restoring at the same time:

```bash
sudo gitlab-ctl stop unicorn
sudo gitlab-ctl stop sidekiq
```

Now we do the actual restore:

```bash
GITLAB_ASSUME_YES=1 /usr/bin/gitlab-backup restore BACKUP=${BACKUPFILE}
```

Secrets are not restored via gitlab-backup restore (go figure):

```bash
cp ${BACKUPDIR}/gitlab-secrets.json /etc/gitlab
```

OPTIONAL: If you are not going to reconfigure from scratch, you need to restore the configuration file. (I don't do this step as I dynamically generate the config script):

```bash
cp ${BACKUPDIR}/gitlab.rb /etc/gitlab
```

IMPORTANT: Restart the services we stopped and allow things to get reconfigured post-restore:

```bash
/usr/bin/gitlab-ctl restart
```

That's it. Go to the hostname in your browser of where your Gitlab Server is running and ensure that your repositories are back.
Clean Code is About Reducing Complexity (Not Improving Readability)
Tags: webdev, javascript, programming
Published: 2022-06-28 17:50:31

When it comes to clean code, there is often an assumption that clean code means readable code.

In other words, the aim of clean code is usually assumed to be making the code as readable as possible.

More readable code is almost always cleaner code. However, it is not at the heart of clean code.

The aim of clean code is to produce _simpler_ code. Code should be reduced to the lowest level of complexity possible while still providing an adequate solution.

So, how can we reduce complexity in software?

The short answer is removing as much cognitive load as possible.

To put it another way, the less thinking that has to be done to make a change the better.
Adidas Logo | Pure CSS
Tags: codepen, css, showdev, beginners
Published: 2022-06-28 17:30:50

In today’s tutorial, I finished creating a Adidas logo with CSS. Simple css code for this iconic staple. Though this is just a fun tutorial, you can practice CSS art to improve your CSS skills. CSS art has been a fun way for me to learn new properties and improve my CSS skills. I have a bunch of CSS art tutorials that are CSS inspired. You can check them out [here](https://codepen.io/rembertdesigns).

For this tutorial, all we need is some basic HTML and CSS.

{% codepen https://codepen.io/rembertdesigns/pen/bGvGRMW %}

If you liked this post, make sure to follow me on [Twitter](https://twitter.com/RembertDesigns) where I post daily about Tech related things!

https://www.buymeacoffee.com/rembertdesigns

### 🌎 Let's Connect

- [Portfolio](https://www.rembertdesigns.co/)

- [Twitter](https://twitter.com/RembertDesigns)

- [Github](https://github.com/rembertdesigns)

- [Codepen](https://codepen.io/rembertdesigns)

- [LinkedIn](https://www.linkedin.com/in/rrembert/)
Back to Back #14 - Back-end news by SFEIR
Tags: newsletter, french, backend
Published: 2022-06-28 17:29:57

_Comme chaque fin de mois, les experts de SFEIR publient la newsletter back-end. Retrouvez la sélection d'articles sur les microservices, les APIs, les bases de données…_ 🕑

---

### 🔒 [Handling Concurrency Without Locks](https://hakibenita.com/django-concurrency)

Un des problèmes récurrents lors de développement d’applications est la programmation concurrente. Ajouter des verrous peut résoudre des problèmes mais on peut vite se retrouver avec une baisse des performances ou pire, des deadlocks. En prenant des cas d’usage en Django, [Haki Benita](https://twitter.com/be_haki) propose dans cet article des astuces pour utiliser un minimum de verrous.

### 📈 [The 2022 API Platform Landscape: Trends and Challenges](https://blog.postman.com/2022-api-platform-landscape-trends-and-challenges)

[Abhinav Asthana](https://twitter.com/a85), CEO et fondateur de Postman, a publié sur son blog les dernières tendances et les derniers défis ainsi qu'une mise à jour du paysage des plateformes API. L'approche API-first a le vent en poupe !

### 💭 [Best Practices for Naming Variables: What the Research Shows](https://thenewstack.io/best-practices-for-naming-variables-what-the-research-shows/)

La linguistique à l’aide de l’informatique. [Felienne Hermans](https://twitter.com/felienne) a conçu un guide qui, selon elle, "nous aidera à mieux nommer les choses". À l’instar des code smells, les linguistic smells sont des mauvaises pratiques qui peuvent conduire à de mauvaises surprises et qu’il faut éviter. Selon des travaux scientifiques, ces smells augmentent la charge cognitive des développeurs.

### 📁 [Why ENV Variables are no Good Anymore](https://hackernoon.com/why-env-variables-are-no-good-anymore/)

Il est fortement probable que vous ayez des fichiers .env actuellement sur votre ordinateur. C’est une solution simple et rapide mais qui possède des défauts, notamment en termes de sécurité. [Pragati Verma](https://twitter.com/pragati_verma18) pense qu’il est l’heure de passer à une nouvelle génération de stockage de variables d’environnement.

### ☸️ [Fixing the Developer Experience of Kubernetes Port Forwarding](https://inlets.dev/blog/2022/06/24/fixing-kubectl-port-forward.html)

Finissons cette revue de presse avec [Alex Ellis](https://twitter.com/alexellisuk) qui nous propose une alternative à la commande `kubectl port-forward`. Le port-forwarding est très pratique mais plusieurs inconvénients peuvent gâcher la _developer experience_ : devoir lancer la commande pour chaque service, retenir quels ports sont déjà pris, devoir relancer la commande en cas de déconnexion…

---

_Les Sfeiriens se mettent en pause cet été. On se retrouve fin août pour préparer la rentrée !_
React Tutorial - Part#1
Tags: beginners, react, discuss, webdev
Published: 2022-06-28 17:27:32

React tutorial makes basic and professional concept strong of React JS. Currently, ReactJS is too popular JavaScript front-end libraries that contain a good and large community.

React is used to make build flexible and reusable UI, ReactJS also gets the benefits of being a declarative, efficient JavaScript library. It’s too popular in market nowadays since it’s made, used and maintained by Facebook, also Facebook uses react for Instagram and WhatsApp.
23 Signs of a Toxic Web Development Work Environment
Tags: webdev, toxic, workplace, redflags
Published: 2022-06-28 17:22:54


[![Watch the full video](https://esteecodes.com/wp-content/uploads/2022/06/23-signs-toxic-workplace-thumbnail-play.jpg)](https://www.youtube.com/watch?v=akj2lOkZd4A "23 Signs of a Toxic Web Development Workplace")
alt="text" Attribute language
Tags: webdev, beginners, discuss, html
Published: 2022-06-28 17:22:26

I'm interested in the alt="text" attribute, specifically the language used within the text area.

I understand that in many ways this is used as a backup redundancy in case an image is not displayed correctly, but would it not add value to users using screen readers for example to put more descriptive, emotive language in there?

In the basic explanation of the attribute on w3schools website they give the following:


I'm just wondering if something structured and approached from this perspective wouldn't add value overall, thoughts?

I'd love to hear what everyone else thinks, I know it's not exactly the hot topic 😁

Admittedly it does look terrible when the image doesn't show and instead you're presented with a wall of text 


alt="Computer"
alt="Phone"
alt="Cup of coffee"


Would it cause any reduction in satisfaction for any other user by implementing something more like this for example:


alt="A MacBook Pro laptop computer with the lid open on the desktop"
alt="An iPhone 6 or 6s Smartphone on the desktop"
alt="A delicious looking Cup of warm espresso coffee in a small single serving"

(As an aside... This is why coding will never catch on, en masse, it's way too involved just to comment!)
Are you ready for your FAANG Interview? - Free Quiz
Tags: webdev, programming, career, tutorial
Published: 2022-06-28 17:18:28

Gauging how prepared someone is for a big tech interview is a tricky thing to do. There are hundreds of questions an interviewer could ask and they have complete control of which one they chose. You could get something random that has never been asked before, which can make preparation seem impossible. 

The good news is that most interviewers behave within a certain bounds. This means you can prepare and have a 90%+ chance of being ready for it. So while nothing is 100%, this quiz includes the same general questions that I ask the [Hackpack](https://www.hackpack.io/) community to gauge if they are 90%+ ready for their interview. 

After you take the quiz, you will be emailed with a % score on how ready you are for the interview! Enjoy! 

Link to Quiz: [https://www.hackpack.io/ready-faang-interview](https://www.hackpack.io/ready-faang-interview)

###Join the community

Looking for a study partner? Hackpack is the most active community of engineers studying for programming interviews. We hold each other accountable, provide support, and fight burnout to study more efficiently and get the job faster.

Apply [Here](https://www.hackpack.io/) 

[Events](https://discord.gg/VQkMr234zk?event=970275330294153257) | [Youtube](https://www.youtube.com/channel/UCfotE5RL1pfhIZ0fv2kAN9Q) | [Twitter](https://twitter.com/hackpack_) | [LinkedIn](https://www.linkedin.com/company/hackpack-io/?viewAsMember=true) | [Newsletter](https://fangprep.substack.com/)
Day 6 : 100DaysOfSwift🚀
Published: 2022-06-28 16:30:57

## Day 6
## Closures Part 1

In Swift, a closure is a special type of function without the function name


Example 

```
let Sau = {
    print("I'm Saurabh, iOS developer")
}

//call the Closure
Sau()
```
2.Closure with Parameter

We don't use the **func** keyword to create closure. Here's the syntax to declare a closure:

```
{ (parameters) -> returnType in
   // statements
}
Here,
```

**parameters** - any value passed to closure
**returnType** - specifies the type of value returned by the closure
**in (optional)** - used to separate parameters/returnType from closure body

Example

```
let Sau={ (name:String) in
print("MySelf \(name)")
}

//Call the Closure
Sau("Saurabh")
```
## return value in Closure
If we want our closure to return some value, we need to mention it's return type and use the return statement. For example,

```
/ closure definition
var findSquare = { (num: Int) -> (Int) in
  var square = num * num
  return square
}

// closure call
var result = findSquare(3)

print("Square:",result)
```

## Closure as parameter
 closures can be used just like strings and integers, you can pass them into functions.

```
let driving = {
    print("I'm driving in my car")
}

func travel(action: () -> Void) {
    print("I'm getting ready to go.")
    action()
    print("I arrived!")
}

travel(action: driving)
```
If we wanted to pass that closure into a function so it can be run inside that function, we would specify the parameter type as () -> Void. That means “accepts no parameters, and returns Void” – Swift’s way of saying “nothing”.
Can we afford ignoring the "OpenSource contributor" part of candidate's resume?
Published: 2022-06-28 17:04:03

I had an interesting chat with a friend of mine today. Basically he insisted that although he has “two interesting #OpenSource projects”, agents never asked him about his contributions on GitHub. He also insisted that he will not even look at a person's GitHub, even if it states “OSS contributor”.

To my surprise, my friend is partially right here. If a person creates an “interesting project”, which brings no value to the society - why should I care? It might demo some coding skills or might not.

However, if somebody translated an OSS project to Hindi, so a wider group of people can start using it - well, I will be VERY interested in interviewing this person. I already know that this person is aimed at bringing value to society. If that person also loves the process of contributions - we are dealing with an amazing human being, who should be hired asap.

At the end of the day, people are hired to bring an impact, not to “write code for fun” or to “build the most perfect algorithm”, unless the last two impact society in a positive way.

To conclude, I would be interested in hiring Linus Torvald-like-minded-in-OSS people not because they are the best in some algorithms. I am sure they are not. However I know that hiring such a person will create a huge positive impact and value to the company. So there is a point to pay well above the “market rate” to this person, as the business value created is “highly likely” to be huge.

I understand there are always “corner cases”, but I hope you’ve got my point :)

If I still haven’t convinced you - please join our meetup [Together we #OpenSource](https://www.meetup.com/togetherweopensource/ ) and we will help you to find your love in OSS world and start contributing to it, while benefiting the society.

Why join our meetup? The reasons are many, some of them are:

- it is fun
- it is free
- it happens regularly, 2 times each Sunday (to allow people from different time zones to take part)
- our main goal is to help people from underprivileged  or under-represented backgrounds and we do deliver
- we accept everybody, given you are of a good character (0 tolerance to racism, hate speech or any other kind of discrimination)
- you may end up getting a luxury job in IT :)


Special thanks to Ivan Kostruba, who inspired me to write this article by providing his positive feedback and criticism of my ideas.