Skip to content

Instantly share code, notes, and snippets.

Avatar

Valentin Radulescu RadValentin

View GitHub Profile
@RadValentin
RadValentin / dabblet.css
Created Oct 22, 2013
GARBAGE - MS 70-480
View dabblet.css
/**
* GARBAGE - MS 70-480
*/
body{
background: #000;
min-height: 100%;
font-family: sans-serif;
color: #fff;
}
a{
View gist:1a73661be9a1769f87bd

github-changelog

NEED

As a user
I want to be able to get notifications about new changes to an application
So that I can stay informed and be able to reload the application at my own will
@RadValentin
RadValentin / gist:89b0fd3b8f1ffdc15c85
Last active Aug 29, 2015
changelog wiki: html structure
View gist:89b0fd3b8f1ffdc15c85

HTML Structure

Changelog Wrapper

The widget is contained within an element with the class .changelog-wrapper

<div class="changelog-wrapper">
...
</div>

Notification button

View gist:e8bb45aa7c6439b30c90

Need

Build LESS styling to support HTML structure so that it can be integrated with the plugin

Deliverables

  • LESS files and the generated CSS for styling and positioning the notification list

Solution

We'll need to create styling for the following:

  1. A notification button with a badge to show the number of new notifications
  2. A notification list that can be positioned according to it's css class with 4 main positions: top, bottom, left and right. Each of these positions can be modified by providing a second class: pull-left and pull-right for vertical positions and pull-top for horizontal positions. The purpose here is to make the list usable in any positioning scenario.
View gist:f11d5af484179d711d8c

Need

We need a way to get the title and label for issues on a given branch on GitHub that are newer than a provided timestamp and that have a certain label(different from the one being returned)

Deliverables

  • Methods that integrate with the GitHub API and that will filter and extract titles and labels according to the provided timestamp, branch and label

Solution

@RadValentin
RadValentin / changelog-blog
Last active Aug 29, 2015
Changelog Blog Entry
View changelog-blog
#github-changelog a robust notification system built on top of GitHub
##What is it?
Building a large web app that needs to be updated frequently can sometimes present interesting challenges. When pushing out an update do you force your users to reload the entire app so they're always running the latest version? Or do you keep the update silent and hope everything works out somehow?
Obviously the first version is better but not perfect. Ideally you'd want your users to know about the update but they should be able to reload at their own will without fear of losing state.
This is where [github-changelog](https://github.com/uberVU/github-changelog/) comes in. By using this simple jQuery plugin, every time an issue is closed on your GitHub repo, your users will get notified.
![changelog demo](https://dl.dropboxusercontent.com/u/42934143/images/demos/changelog-anim.gif)
@RadValentin
RadValentin / Preferences.sublime-settings
Last active Aug 29, 2015
Common Sense Sublime Text Settings
View Preferences.sublime-settings
{
"color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme",
"ensure_newline_at_eof_on_save": true,
"font_size": 12,
"ignored_packages":
[
"Vintage"
],
"rulers":
[
@RadValentin
RadValentin / linebreak-style.md
Created Mar 4, 2017
How to stop ESLint/XO CRLF linebreak-style warnings in Windows
View linebreak-style.md

If you clone a git repo that enforces a linebreak-style: unix on a Windows machine then ESLint will probably throw the warning below even if you've made no local changes.

Expected linebreaks to be LF but found CRLF.  linebreak-style

In order to fix this you'll need to tell git to default to Unix style line endings rather that OS defaults.

git config --global core.eol lf
git config --global core.autocrlf input
@RadValentin
RadValentin / yarn.unlock.md
Last active Jun 21, 2021
Solve `yarn.lock` or `package.json` conflicts without losing your mind
View yarn.unlock.md

NOTE: This guide is ONLY for devs who don't want to edit their yarn.lock file by hand. If you don't care about that please carry on.


So you've pulled the latest master

git checkout master
git pull
@RadValentin
RadValentin / 7-lines-of-code.json
Last active Dec 21, 2017
Make billions with these seven lines of code (Visual Studio Code HTML Snippet)
View 7-lines-of-code.json
{
"$9.2 Billion Startup": {
"prefix": "disrupt",
"body": [
"<ul>",
"</nav>",
"</dl>",
"aliqua. Ut",
"uat.</dd>",
"</ul>",