teleren/devto huggingface dataset:
Notion.so data sharing with transclusion
Published: 2019-03-12 08:03:53

---
title: Notion.so data sharing with transclusion
published: true
description: A simple programming example of transclusion
tags: 
---
Developers without much of a background in Functional Programming or Category Theory may struggle when first confronted with the idea of a "topology" or "working surface" when doing programming.

Usually that sort of creature shows up when trying to debug a program or perform introspection through code and data.

The idea of treating the programming medium itself as some sort of walkable "surface" is more common in operating systems (think filesystems) or databases (think spreadsheets or graphs etc.) but this is also how web documents such as XML and HTML etc. operate.

In fact, the main reason why we use interim documents like XML and HTML is exactly to allow us to move between programming and topology (actually algebraic geometry).

Transclusion is the idea of having the same data show up in multiple places, most famously being Notion.so. The person behind Notion.so is Ted Nelson. It is essentially a way to perform data normalization.

Below, we use the NodeServerless REPL to demonstrate some of this 'transclusion' by having the variable "here" also projected to a variable "there". We did this by using the "ln" or "link" command similar to what is found in Linux. Note that in practice, both variables would probably pull from a common location. 

The linking mechanics are fairly straightforward using JS proxies (as indicated with the pink arrows).

![](https://thepracticaldev.s3.amazonaws.com/i/iy5tg53qt7zf5kmwvixu.png)

I hope this helps explain such a powerful concept without getting into heavy math. Transclusion is key to how spreadsheets work and the functional dependency calculations behind them (which gets more into category theory).

NodeServerless is now part of CodeCraft.AI
I’m Running for the .NET Foundation’s Board of Directors!
Tags: dotnet, community, leadership, opensource
Published: 2019-03-19 20:55:52

---
title: I’m Running for the .NET Foundation’s Board of Directors!
published: true
tags: dotnet,community,leadership,oss
canonical_url: https://seankilleen.com/2019/03/running-for-the-dotnet-fdn-board/
---

I’m excited to announce [my candidacy for the .NET Foundation’s Board of Directors](https://election.dotnetfoundation.org/campaign-2019/sean-killeen.html)!

I believe transparent, community-focused governance and OSS involvement is vital to the future of .NET’s success, and I’d be excited to support that however I can.

## I’m interested in your thoughts!

This post is short because my candidacy page has most of my thoughts, but I’m more interested in what _you_ think.

- What are the challenges facing the .NET Foundation?
- How are you looking to be represented?
- What do you think a .NET Foundation board member should be doing to support the .NET community?
- Is there anything you wish you knew about the Foundation, me, or my candidacy?

I created a process and submitted some PRs so that you can [ask questions of all the .NET Foundation Board candidates](https://election.dotnetfoundation.org/questions)! I hope you'll do so.
How to keep programming related notes
Tags: webdev, programming, productivity
Published: 2019-03-12 06:58:32

---
title: How to keep programming related notes
tags: webdev, programming, productivity
cover_image: https://www.kozubek.dev/assets/images/2-notebook.jpg
canonical_url: https://www.kozubek.dev/2019/03/11/programming-notes.html
description: How to keep code snippets/notes as a programmer 🧐?
published: true
---

> Originally posted on [kozubek.dev](https://www.kozubek.dev/2019/03/11/programming-notes.html)

Inspired by "The Pragmatic Programmer" book and "sharpening the saw" idea, I will write some posts on tools I use every day to be a more efficient developer. [Lepton gist client](http://hackjutsu.com/Lepton/) is a way to keep your notes organized.

## Why? 🤔

Once I found I need a systematic way to keep notes. There is something to learn each day and keeping notes:

1. helps to memorize stuff important for you,
2. with writing you go to another level of understanding since you need to explain it to your future self (at least),
3. if you keep it organized you will easily find an answer for a problem you already solved once but forgot.

Above combined makes you a more efficient developer 🤓

## Options:

### Notebook 

I keep some stuff written in notebook or post-its. With a pen and paper you can express your thoughts quick and easy.

But you don't want to keep code snippets or shell commands in your notebook to use daily. You would rather put that stuff in more copy-paste friendly environment.

I still use a notebook with my calendar to sum-up challenges I met every day. I write them as short tags I can recognize in few next days. When I find the time I evaluate them into digital notes with code snippets or so.

### Google Keep

Someday I started using Google Keep. It is a simple app, has a nice UX and integrates easily with Chrome, Gmail, Google Calendar. What I missed is a code snippets/markdown support which is crucial to keep software related notes. The same goes for Evernote and every usual note capturing app.

### Github gists

Most of us developers use Github every day to store git repositories and handle code development. The lesser-known Github feature is gists, they are something more light - you can keep code and markdown snippets there and then share easily.

But it lacks good UX. You can't categorize them, can't search through them quickly. So I use them as a storage for my notes + I can embed them easily in HTML as below:

<script src="https://gist.github.com/archiewald/783deb46a1e75e69f3898d6fa052fdae.js"></script>

## Final choice - Lepton gist client!

Finally, I found an open-source desktop app which meets my expectations. [Lepton gist client](http://hackjutsu.com/Lepton/) synchronizes with your GitHub account and lets you handle your snippets more efficient:

- add a new one with keyboard shortcuts,
- categorize via hashtags and snippets type,
- search through your gists easily,
- do all above with intuitive keyboard shortcuts.

Handling gists is a breeze now 🌊 Check out a short video on that below:

{% youtube ozrKcOuOdZU  %}
Introduction into Logging with Loguru
Tags: programming, cpp, introduction
Published: 2019-05-17 12:03:32

---
title: Introduction into Logging with Loguru
published: true
tags: programming,CPP,introduction
canonical_url: https://thoughts-on-cpp.com/2019/03/12/introduction-into-logging-with-loguru/
---
Postet on [thoughts-on-cpp.com](https://thoughts-on-cpp.com)

This time I would like to give a short introduction into a nice little library I just encountered. It’s called [loguru](https://github.com/emilk/loguru/blob/master/README.md) and it’s a lightweight, Thread-Safe, logging library with an impressive good written [documentation](https://emilk.github.io/loguru/index.html) and human-readable output.

To use it all you need to do is to add a single header and source file to compile with. Unfortunately, that’s, in my opinion, also a drawback. Yes, it’s easier to install and usable in training, but it can’t be exchanged by whoever is operating the system after deployment. In such cases, where the operator wants to define how and what to use for logging, a generic logging interface (facade pattern), such as [slf4cxx](https://archive.codeplex.com/?p=slf4cxx) which is similar to its java pendant [slf4j](https://www.slf4j.org), would be preferable.

Loguru is supporting a various number of features, such as callbacks for logging and fatal errors, verbosity levels, assertions and aborts, and stack traces in case of aborts. It even supports [{fmt}](https://github.com/fmtlib/fmt). Everyone who ever was used to java/spring log outputs will recognize its similarities.

{% gist https://gist.github.com/Ben1980/cb77c95e24130ab376f6f72c42d26a8c %}

{% gist https://gist.github.com/Ben1980/3002789766cd02d812de745110c6f86e %}

As you can see it’s pretty straight forward to use. We are not only logging several messages on INFO verbosity level, but also a message in a named thread called “complex lambda”. If we wouldn’t have defined the thread name with loguru::set\_thread\_name(“complex lambda”), loguru would state the name of a thread with a hex id. The main thread gets its name by calling loguru::init(…). Because our small tool is crashing, loguru is printing us a stack trace which in my opinion is not as helpful as expected, but with ERROR\_CONTEXT we get a little better output.

That’s it for now with this post. We have now a short introduction into a, until now, rather unknown, but promising, logging library. Loguru is not only capable of producing Thread-Safe and human readable logging messages but also provides a very simple and handy interface to use.

Did you like the post?

What are your thoughts?

Feel free to comment and share the post.
Developed a test framework for Rust (Try use it)
Tags: rust, showdev
Published: 2019-03-12 04:18:48

---
title: Developed a test framework for Rust (Try use it)
published: true
description: write like Rspec testing framework with rust
tags: #rust #showdev
---

Hi. I'm nasa.

I made a test framework Ruspec by Rust.
Please use it.

https://github.com/k-nasa/ruspec

## Example syntax 

This is functional macro. It's expanded to has test attribute code.

```rust
use ruspec::ruspec;

ruspec! {
    describe "test module name" {
        before { let context = 5; }
        subject { context + 5 }

        it "test name" {
            assert_eq!(subject, 10);
        }
    }

    describe "test module 2" {
        before { let context = 5; }
        it "test name" {
            assert_eq!(context, 5);
        }

        context "context is 6" {
            before { let context = 6; }
            it "should equal 6" {
                assert_eq!(context, 6);
            }
        }
    }
}
```
# Expand
```rust
mod test_module_name {
    #[test]
    fn test_name() {
        let context = 5;

        assert_eq(context + 5, 10)
    }
}

mod test_module_2 {
    #[test]
    fn test_name() {
        let context = 5;

        assert_eq(context, 10)
    }

    mod context_is_6 {
        #[test]
        fn should_equal_6() {
            let context = 6;
            assert_eq!(context, 6)
        }
    }
}
```

## how to use 

Add your Cargo.toml
```
ruspec = "0.1.1"
```

import ruspec!
```
use ruspec::ruspec;
```
Quarkus: Introduction of New Method for Quickly Launching Java applications on  Container
Tags: java, container, graalvm, kubernetes
Published: 2019-03-12 04:02:17

---
title: Quarkus: Introduction of New Method for Quickly Launching Java applications on  Container
published: true
description: Please refer to the article such kind of person who think that starting Java applications on the Docker environment is slow. Java Application started only 0.005 sec in my env!
canonical_url: https://github.com/yoshioterada/k8s-Azure-Container-Service-AKS--on-Azure/blob/master/Introduction-Of-Quarkus.md
tags: Java, Container, GraalVM, Kubernetes
---

Please refer to the article such kind of person who think that starting Java applications on the Docker environment is slow. Java Application started only 0.005 sec in my env!
[Original Document is Here](https://github.com/yoshioterada/k8s-Azure-Container-Service-AKS--on-Azure/blob/master/Introduction-Of-Quarkus.md)
Emoji on VsCode 🔥
Tags: vscode, emoji, vscodeextensions
Published: 2019-03-12 03:15:08

---
title: Emoji on VsCode 🔥
published: true
description: Emoji vscode extension
tags: vscode, emoji, vscode extensions
---

Emoji Snippets help developers to insert emoji on files. You can insert emoji on comments or other parts of your code.

With this extension, you can beautify your comments with 😉

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

Visual Code Extension
https://marketplace.visualstudio.com/items?itemName=devzstudio.emoji-snippets

Extension for Visual Studio Code - Insert emoji to your Vscode files
marketplace.visualstudio.com	
🚀 Usage:

1) Install the Emoji Snippets Extension on Visual Code

2) And when you want to insert emoji just type :keyword and then it will suggest the emoji related to that keyword. You can use the emoji from https://emojipedia.org/ just type : and then the name of emoji.

Contribute 🎉

https://github.com/Devzstudio/Vscode-Emoji-Snippets
I'm a 17 year old university senior who's hyped about jumping into the computer science workforce && Ask me Anything!
Tags: ama
Published: 2019-03-12 01:01:04

---
title: I'm a 17 year old university senior who's hyped about jumping into the computer science workforce && Ask me Anything!
published: true
tags: ama
---

Hi! I'm Mikol Aspinwall, and I'm two months from graduating with my B.A. in Computer Science, and I'm working on a slew of side projects. I've been reading on dev.to for awhile, and it's been pretty beneficial to me; a friend encouraged me to do an AMA on here, so here I am.

Ask me Anything! Alternatively, all guidance, advice, and general wisdom nuggets are gladly accepted.
Javascript: Build a Factorial function using loop and recursion.
Published: 2019-03-11 23:45:03

---
title: Javascript: Build a Factorial function using loop and recursion.
published: true
description: factorial
tags: 
---
<h1>Overview</h1>

<p>Factorial of n means n*(n-1)*(n-2)*(n-3)..., so factorial of 5 would be 5*4*3*2*1 which equal to 120. In this article, we will implement factorial using a simple for loop and a simple recursion, using javascript.</p>

<h2>For loop solution</h2>
{% replit @YongLiang/OtherFoolishSoftwareagent %}
<p>This is a simple loop that iterates as many times as the number n, and times the incrementing i to find the result.</p>

<h2>Recursion solotion</h2>
<p>A recursive function should have two basic components - 1. base case; 2. recursive case. When the base case condition is met, the function will stop, otherwise, the function will keep calling itself, similar to how loops iterate.</p>
{% replit @YongLiang/PristineFamiliarPiracy %}

<p>n is printed in order here because each time the function calls itself, it subtract by 1 until n reaches 1. Notice that each time this function calls itself, the n value updates.</p>
<h2>Knight Tour using backtracking</h2>
<img src="https://thepracticaldev.s3.amazonaws.com/i/6iet6gsydzo95ccdk8c0.gif" >
https://www.geeksforgeeks.org/the-knights-tour-problem-backtracking-1/
Why Do We Write <! DOCTYPE html> ?
Tags: html, beginners, webdev
Published: 2019-03-11 22:12:47

Yes, this is for the absolute beginner, and also for those non-beginners who forgot. I am going to  look back behinds and re-discover things we take as granted by asking "WHAT", "WHY", and "HOW".

---

#### Why do we write <! DOCTYPE html> ?

```html
<!DOCTYPE html>
<html lang="en">
    <head>

    </head>
    <body>

    </body>
</html>
```

`<! DOCTYPE html>` is the first html tag written at the beginning of any html file. It is not an element and doesn't has content or closing tag.
Its job is to tell the browser that the document being rendered is an HTML document. That's the reason for its position to be the first thing the browser read.

---

#### But what would happen if we didn't write it? 

If browser didn't find a [DOCTYPE](https://developer.mozilla.org/en-US/docs/Glossary/Doctype) declaration, it would enter [quirks mode](https://en.m.wikipedia.org/wiki/Quirks_mode)🤔 which is a technique used by browsers to try to support old web pages that has been made for Navigator 4 and Internet Explorer 5. [Read about it here](https://developer.mozilla.org/en-US/docs/Web/HTML/Quirks_Mode_and_Standards_Mode). 
This means that your website will have different behavior and look with different browsers especially if it has new HTML elements and features.
XFCE blank/black screen with cursor after login (solution)
Tags: xfce, linux
Published: 2019-03-11 21:21:56

---
title: XFCE blank/black screen with cursor after login (solution)
published: true
description: 
tags: xfce,linux
---

Recently I had an issue where I would get a blank screen after booting up and starting XFCE from my display manager (LightDM, if it matters). No panel, no icons, no desktop, just my cursor. This began after uninstalling GNOME (and reoccurred after installing i3). As a workaround I could just switch back and forth between TTYs (i.e. Ctrl + Alt + F6 then Ctrl + Alt + F7) and that would finally start up my desktop. But today I have found a real solution.

**The solution for me was to delete** `~/.config/xfce4/xfconf/xfce-perchannel-xml/displays.xml` as suggested on [the Arch wiki](https://wiki.archlinux.org/index.php/Xfce#Black_screens_at_boot_with_NVIDIA_and_multiple_monitors) and on [this thread from the Nvidia forums](https://devtalk.nvidia.com/default/topic/1029381/linux/black-screen-at-desktop-login-gtx-750-ti-390-25-/3?fbclid=IwAR23GSnvpGS3IKRfYFqdS3ma1Je9NLfkbVemqwHMVT02P_nlZ3BSswnkMiw) (this also seems to be an issue with multiple monitor setups).

Searching for this issue online yielded very little, and led to me only temporarily solving the problem the first time by deleting all of my XFCE settings [as suggested on the Arch forums](https://bbs.archlinux.org/viewtopic.php?id=143529) (**do not do that**, that is a _pain_ to set back up if you've dumped as much time into your settings as I have). I only happened to come across the solution while reading the aforementioned XFCE page on the Arch wiki. So hopefully I've dropped enough keywords in this post to help the next unlucky desktop-environment-hopper or multi-monitor-power-user that searches for this issue, and if you're that person, thanks for reading.
Docker images and playing cards: a security illustration
Tags: docker, security
Published: 2019-03-11 20:58:16

---
title: Docker images and playing cards: a security illustration 
published: true
description: The use of minimal Docker images and the associated security benefit.  
tags: docker, security
---
_For security insights into the top docker images, [click here](https://snyk.io/blog/top-ten-docker-images-contain-over-8000-vulnerable-paths/) to read more._ 


__Let's talk Docker security by using a thought experiment.__ 

Imagine you are going to build a stack of cards representing a Docker image. If a card has an _X_ on it, that represents a security vulnerability. You start with an initial deck. You may not need all of the cards in the deck strictly speaking, but they came out of the box together so you keep them. You go around to your friends, colleagues, and internet strangers and accept cards from them to add to your deck to add functionality. You don’t scan the cards you receive from these people because you either trust them, or more likely you are focused on building your deck, not looking for _Xs_ on cards. You also may not need all of those cards, but you have bigger fish to fry. 

By the time you have finished, do you know how many _Xs_ are present in your deck? Do you know whether they are part of your your original card deck or in the cards you added from your friends? 

Do you know whether the _Xs_ exist on cards that are really required or on cards that are just in the deck because you haven’t taken the time to sort them out? 

If you wanted to minimize the number of _Xs_ in your stack of cards, it would make sense to start with a smaller initial stack of cards, consisting of only the ones you need, and being more selective and careful about the other cards you add to your deck. 

This thought experiment gives us a good idea of why _minimal images_ in docker are a good idea from a security perspective. __By preferring minimal images that bundle only the necessary system tools and libraries required to run your project, you are minimizing the attack surface for bad actors.__ 

If you only need thirty cards, don't use a deck of 70.

 
_For security insights into the top docker images, [click here](https://snyk.io/blog/top-ten-docker-images-contain-over-8000-vulnerable-paths/) to read more._
The 7 Most Popular DEV Posts from the Past Week
Tags: top7
Published: 2019-03-11 20:52:25

Every Monday we round up the previous week's top posts based on traffic, engagement, and a hint of editorial curation. The typical week starts on Monday and ends on Sunday, but don't worry, we take into account posts that are published later in the week. ❤️

#1. Beyond The Basics

Chris shares a first part series on docker: from a high level overview to a deep dive on docker compose.  

{% link https://dev.to/softchris/5-part-docker-series-beginner-to-master-3m1b %}

#2. Save Your Butt

...by knowing these tricks! Ankur shares some git tips with the community - fixing or _amending 😜_ a commit message, changing branch names, and more!

{% link https://dev.to/teamxenox/git-hacks-you-should-know-about-16pk %}

#3. Bad DX

Marek dives into reasons why programming languages often have a barrier to entry and what experienced developers can do to make it easier on a newbie. 

{% link https://dev.to/marek/why-programming-languages-are-hard-19ch %}

#4. It's a tree!

Kara shares an overview of the Document Object Model.

{% link https://dev.to/karaluton/what-exactly-is-the-dom-jhg %}

#5. Problem Solving

It's easy for us to start solving a problem without knowing all the details. John shares three things to do to ensure we're targeting and answering the _right_ problems.

{% link https://dev.to/azure/3-things-you-can-do-to-improve-as-a-developer-1kip %}

#6. Exit the loop!

Devon describes the gratification of completing a tutorial, and then explains how it could stunt your growth as a developer. 

{% link https://dev.to/raddevon/stop-doing-coding-tutorials-1o4l %}

#7. It's "The Code"

When you're a solo dev, you don't really need to do any code reviews. Jacque shares the code review tips they picked up after their team grew from one to three. 

{% link https://dev.to/jnschrag/10-lessons-learned-conducting-code-reviews-5di6 %}

_That's it for our weekly wrap up! Keep an eye on dev.to this week for daily content and discussions...and if you miss anything, we'll be sure to recap it next Monday!_
Nevertheless, Anna Still Codes
Tags: wecoded
Published: 2019-03-11 20:20:08

---
title: Nevertheless, Anna Still Codes
published: true
description: 
tags: shecoded
---

In 2019, I continue to code, mentor, and write because I love the challenge—I've left previous careers due to boredom and lack of engagement. My job is a lot of things, but boring is sure not one of them!

I think I do deserve some credit for the amount of personal growth I've packed into the past year. I've practiced my writing, improved my knowledge around lower-level tools and infrastructure, and taken some big strides in demonstrating leadership and responsibility on my team and within my organization as a whole. I've pushed through some intense stress and anxiety to overcome my own limitations (and discovered brand new limitations!).

This year, I hope to see even more intermediate and advanced community-led programming training proliferate in tech! We could all use more mid-level and senior developers, but we won't see them shine until we help them grow.