Monthly Shaarli
January, 2020
Built to last at least 100 years, not discriminate between objects, files etc, open source, free, and so on.
A Rofi modi that allows controlling rofi content throug communication with an external program - OmarCastro
Python PDF Parser -- fork with Python 2+3 support using six - pdfminer
A small utility making use of the pypdf library to provide a (somewhat) lighter alternative to pdftk - hellerbarde
allows differentiating between physical and logical pages, might be useful
Tutorials, Cheatsheets and Applications
I’m a sophomore in high school and I’ve wanted to go into the psychology field for years, specifically social psychology. I often find myself...
People, however, usually choose permissive when they want a mutual collaboration that can be easily integrated into other products and services without licensing headaches and complications.
When you depend on an open-source project to succeed you're likely going to deploy developers on it regardless of its license, and while permissive licenses do not make contributions mandatory you'd probably want to upstream them anyway so you can get help on maintaining the improvements.
There are a billion examples that can be given, but we can use the classic one. FreeBSD has gotten several improvements to its networking stack from Netflix, multiple changes to its graphics stack from Sony including some AVX acceleration that didn't even exist before. Apple is also known to periodically submit a bunch of their changes, on top of already making most of the core pieces of OSX open.
Now you might ask me "and why not just use the GPL to force them into contributing?" Because sometimes they have a reason for not opening parts of their code, if they can't use a good piece of copy-left software they will just make their own, which will probably be worse depending on how big the other project was, and in the end you're just getting a shittier product in the market.
What is currently happening, is the path to fascism. To be clear i dont mean this is the beginning of a new nazi empire that will gas and exterminate people. This is the path of a country that is on its way to radical authoritarian nationalism.
Dr. Lawrence Britt has examined the fascist regimes of Hitler (Germany), Mussolini (Italy), Franco (Spain), Suharto (Indonesia) and several Latin American regimes. Britt found 14 defining characteristics common to each:
Powerful and Continuing Nationalism - Fascist regimes tend to make constant use of patriotic mottos, slogans, symbols, songs, and other paraphernalia. Flags are seen everywhere, as are flag symbols on clothing and in public displays.
Disdain for the Recognition of Human Rights - Because of fear of enemies and the need for security, the people in fascist regimes are persuaded that human rights can be ignored in certain cases because of "need." The people tend to look the other way or even approve of torture, summary executions, assassinations, long incarcerations of prisoners, etc.
Identification of Enemies/Scapegoats as a Unifying Cause - The people are rallied into a unifying patriotic frenzy over the need to eliminate a perceived common threat or foe: racial , ethnic or religious minorities; liberals; communists; socialists, terrorists, etc.
Supremacy of the Military - Even when there are widespread domestic problems, the military is given a disproportionate amount of government funding, and the domestic agenda is neglected. Soldiers and military service are glamorized.
Rampant Sexism - The governments of fascist nations tend to be almost exclusively male-dominated. Under fascist regimes, traditional gender roles are made more rigid. Divorce, abortion and homosexuality are suppressed and the state is represented as the ultimate guardian of the family institution.
Controlled Mass Media - Sometimes to media is directly controlled by the government, but in other cases, the media is indirectly controlled by government regulation, or sympathetic media spokespeople and executives. Censorship, especially in war time, is very common.
Obsession with National Security - Fear is used as a motivational tool by the government over the masses.
Religion and Government are Intertwined - Fascist governments use the most common religion in the nation as a tool to manipulate public opinion. Religious rhetoric and terminology is common from government leaders, even when the major tenets of the religion are diametrically opposed to the government's policies or actions.
Corporate Power is Protected - The industrial and business aristocracy of a fascist nation often are the ones who put the government leaders into power, creating a mutually beneficial business/government relationship and power elite.
Labor Power is Suppressed - Because the organizing power of labor is the only real threat to a fascist government, labor unions are either eliminated entirely, or are severely suppressed.
Disdain for Intellectuals and the Arts - Fascist nations tend to promote and tolerate open hostility to higher education, and academia.
Obsession with Crime and Punishment - Under fascist regimes, the police are given almost limitless power to enforce laws. The people are often willing to overlook police abuses and even forego civil liberties in the name of patriotism. There is often a national police force with virtually unlimited power in fascist nations.
Rampant Cronyism and Corruption - Fascist regimes are governed by groups of friends and associates who appoint each other to government positions and use governmental power and authority to protect their friends from accountability. It is common in fascist regimes for national resources and treasures to be appropriated or outright stolen by government leaders.
Fraudulent Elections - Sometimes elections in fascist nations are a complete sham. Other times elections are manipulated by smear campaigns against or even assassination of opposition candidates, use of legislation to control voting numbers or political district boundaries, and manipulation of the media. Fascist nations also typically use their judiciaries to manipulate or control elections.
Umberto Eco's list (paraphrased from this essay)
The cult of tradition. “One has only to look at the syllabus of every fascist movement to find the major traditionalist thinkers. The Nazi gnosis was nourished by traditionalist, syncretistic, occult elements.”
The rejection of modernism. “The Enlightenment, the Age of Reason, is seen as the beginning of modern depravity. In this sense Ur-Fascism can be defined as irrationalism.”
The cult of action for action’s sake. “Action being beautiful in itself, it must be taken before, or without, any previous reflection. Thinking is a form of emasculation.”
Disagreement is treason. “The critical spirit makes distinctions, and to distinguish is a sign of modernism. In modern culture the scientific community praises disagreement as a way to improve knowledge.”
Fear of difference. “The first appeal of a fascist or prematurely fascist movement is an appeal against the intruders. Thus Ur-Fascism is racist by definition.”
Appeal to social frustration. “One of the most typical features of the historical fascism was the appeal to a frustrated middle class, a class suffering from an economic crisis or feelings of political humiliation, and frightened by the pressure of lower social groups.”
The obsession with a plot. “The followers must feel besieged. The easiest way to solve the plot is the appeal to xenophobia.”
The enemy is both strong and weak. “By a continuous shifting of rhetorical focus, the enemies are at the same time too strong and too weak.”
Pacifism is trafficking with the enemy. “For Ur-Fascism there is no struggle for life but, rather, life is lived for struggle.”
Contempt for the weak. “Elitism is a typical aspect of any reactionary ideology.”
Machismo and weaponry. “Machismo implies both disdain for women and intolerance and condemnation of nonstandard sexual habits, from chastity to homosexuality.”
Selective populism. “There is in our future a TV or Internet populism, in which the emotional response of a selected group of citizens can be presented and accepted as the Voice of the People.”
Ur-Fascism speaks Newspeak. “All the Nazi or Fascist schoolbooks made use of an impoverished vocabulary, and an elementary syntax, in order to limit the instruments for complex and critical reasoning.”
Paxton's Delineation of Five Stages
Disillusionment with democracy— “fascisms take their first steps in reaction to claimed failings of democracy … In the late nineteenth and early twentieth centuries, thinkers and publicists discredited reigning liberal and democratic values, not in the name of either existing alternative — conservative or socialist — but in the name of something new that promised to transcend and join them: a novel mixture of nationalism and syndicalism that had found little available space in a nineteenth-century political landscape compartmented into Left and Right”
Fascism joins the political establishment — “The second stage — rooting, in which a fascist movement becomes a party capable of acting decisively on the political scene — happens relatively rarely … Success depends on certain relatively precise conditions: the weakness of a liberal state, whose inadequacies seems to condemn the nation to disorder, decline, or humiliation; and political deadlock because the Right, the heir to power but unable to continue to wield it alone, refuses to accept a growing Left as a legitimate governing partner … Every fascist movement that has rooted itself successfully as a major political contender, thereby approaching power, has betrayed its initial antibourgeois and anticapitalist program.”
Arrival to power — “fascism has never so far taken power by a coup d’état, deploying the weight of its militants in the street … The only route to power available to fascists passes through cooperation with conservative elites. The most important variables, therefore, are the conservative elites’ willingness to work with the fascists (along with a reciprocal flexibility on the part of the fascist leaders) and the depth of the crisis that induces them to cooperate … Neither Hitler nor Mussolini took the helm by force, even if they used force earlier to destabilize the liberal regime and later to transform their governments into dictatorships. Each was invited to take office as head of government”
Exercise of power— “fascist leaders who have reached power, historically, have been condemned to govern in association with the conservative elites who had opened the gates to them. Fascist rule is unlike the exercise of power in either authoritarianism (which lacks a single party, or gives it little power) or Stalinism (which lacked traditional elites). Authoritarians would prefer to leave the population demobilized, while fascists promise to win the working class back for the nation by their superior techniques of manufacturing enthusiasm.”
Radicalization or entropy— the fascistic government descends either into authoritarianism, or becomes radicalized, as Nazi Germany did, devolving into ethnic cleansing.
Extract clean(er), readable text from web pages via Mercury Web Parser API. - jarun
Commandline tool to customize Spotify client. Supports Windows, MacOS and Linux. - khanhas
Extracts and formats text annotations from a PDF file - 0xabu
I want a python function that takes a pdf and returns a list of the text of the note annotations in the document. I have looked at python-poppler
Journal of Open Source Software (JOSS) is a developer friendly, open access journal for research software packages.
Podcasts about Free Software for Scientists
incredible git aliases
excerpts:
- find branches by grepping for parts of their name in your codebase
- get summaries of your own commits and logs since a specific last point in time
- quickly host your own git server to push to, pull from (through gits built in server)
- directly running ci tests/documentation generation/deployments from the commandline through git by using json-parsing and a rest-api
[26:00]
Complete summary at link
Spotify for the terminal written in Rust 🚀. Contribute to Rigellute
Run a long-term vm of Windows10
The scale is irrelevant. This is about a complex web of social taboos and power dynamics we've been taught to accept.
The CEO is a member of "private industry", conducting business we're told we have no right or power to question. They are answerable only to some nebulous "market forces".
The person who receives a "free meal" does so at the "expense" of the ever lauded "honest taxpayer". We're taught that somehow, despite the fact that we can't understand all the details of redistributive policy or a person's circumstances that we have not only the right, but the obligation to make moral judgements about each individual's use of publicly provided money.
So, the "free meal" comes straight from your pocket, but a murderer's golden parachute apparently comes from a system to which you have no connection. We may only fight over designated crumbs. The bread itself is off limits.
All things Vim! Big'ol List of Vim Plugins, separated by use-case
How to avoid merge conflicts in a NEWS or ChangeLog file
Writing Prose in vim, and discussion around it (non-linearity, chunks, modularity, some R discussion)
Pure go library for creating and processing Office Word (.docx), Excel (.xlsx) and Powerpoint (.pptx) documents - unidoc
:bathtub: Clean Code concepts adapted for JavaScript - ryanmcdermott
Introduction When I am writing some prototyping code inside Neovim, I want to run the script without going to the terminal and typing python toy_script.py. Of course, we can use :!python % in the command line to run the script (see :h :!). The problem is that running external command will block Nvim
Laptop battery drain powertop nic:docker0 device
What to do?
_ ifconfig docker0 down
A Glorified WM-Independent Dropdown Creator. For terminal or other programs
Framework to start emacs'ing from, while keeping some of vim's advantages intact.
Extensive README to get some idea of what is going on.
Apparently the most mature Todoist CLI (and most well known , going by stars)
other options:
- shows highlights and annotations
- can create note-based annotations (not highlights though?)
- can be customized to vim-like keys
- minimal interface and distraction
ANSI Codes to change terminals on the fly: https://www.reddit.com/r/unixporn/comments/80nidw/bspwm_script_to_change_all_themes_on_demand/duxjw1e/
corresponding ANSI codes contained here:
https://github.com/chriskempson/base16-shell
alacritty supports hot-reloading of colors on config file changes, but this works for broader range of terminal emulators
Python script to do PDF OCR conversion using Tesseract - virantha
This is also what paperless uses for its OCR process
In i3wm there is a feature that I used a lot and is the ability to create modes and enter them with a combination of keys, once inside it you can...
for stable and more versatile version that can take JSON, BibTex, URL, csv? input, see: https://github.com/larsgw/citation.js/
a bash script using nmcli and rofi to make a wifi menu in i3
- Spaced repetition: People retain information better when they practice retrieval over spaced intervals. These intervals can be increasingly spread out over time. (http://www.few.vu.nl/~vbr240/publications/Scriptie.pdf)
- Interleaving: Interleaving and varied practice help us better assess context and discriminate between problems, selecting and applying the correct solution from a range of possibilities. Note: The order of interleaved topics needs to be shuffled) (Rohrer, D. (2012). Interleaving helps students distinguish among similar concepts. Educational Psychology Review, 24, 355-367.)
- Retrieval Practice: During focused, effortful recall, learning is made pliable again. The most salient aspects become clearer and the consequent reconsolidation helps reinforce meaning, strengthen connections to prior knowledge, bolster cues and retrieval routes, and weaken competing routes. The more difficult it is to retrieve the knowledge, the more you get out of the practice. (https://www.kent.edu/CAS/Psychology/resources/cml/upload/Pyc-Rawson-2009-JML-pdf.pdf; https://journals.sagepub.com/doi/abs/10.1177/0098628314549701)
- Generative Learning: Trying to come up with an answer, even before a solution has been presented. Leads to better learning and stronger retention, even if the answer is wrong. (https://link.springer.com/referenceworkentry/10.1007%2F978-1-4419-1428-6_171)
- Elaboration: The process of finding additional layers of meaning in the material. Connect it to other ideas, expand on it, create metaphors. (Make it Stick - Peter Brown,Henry Roediger,Mark McDaniel)
Render markdown on the CLI, with pizzazz! 💅🏻. Contribute to charmbracelet
Citizens’ Climate Lobby is a non-profit, non-partisan, grassroots advocacy organization focused on national policies to address climate change. Our consistently respectful, non-partisan approach to climate education is designed to create a broad, sustainable foundation for climate action across all geographic regions and political inclinations.
[7:38:19]
VOoM: Vim two-pane outliner.
Outliner functionality for vim -- carry a tree-like structure in a pane alongside your text. Can use markdown/pandoc/rmarkdown and many of the vim outliner plugin markers to generate the outline pane.
Can re-order and organize sections in your text through shortcuts (see gif of it in action on the page) !
Build on Vim’s spell checking and correction. Allows thesaurus substitution, instant dictionary completion and per-file/-environment spell language invocation (through functions, see README)
other spelling plugins:
- https://github.com/dbmrq/vim-dialect - persist zG/zW per-file or per-directory instead of loosing them after closing vim
- https://github.com/inkarkat/vim-SpellCheck - populate quickfix window w/ spelling errors
- https://www.reddit.com/r/vim/comments/9gkofj/storing_custom_spell_check_word_lists_in_git/ - when storing spellfile in vcs automatically rebuild in vim on starting so that it stays up to date
useful tips for configuring some spell-checker settings and mappings: https://www.reddit.com/r/vim/comments/41a3cw/better_way_of_doing_spellcheck/
- reddit.com -> getting too large for its own good?
- lobste.rs -> invite-only, exclusive; leaning towards programming and sciences
- hackernews -> high-brow but somewhat abrasive; heavily leaning toward programming and unix
- littr.me -> federated reddit clone; very light-weight; almost no discussion yet
- lemmy -> federated reddit clone; light-weight; few users but some discussion happening; could use content
A list of SaaS, PaaS and IaaS offerings that have free tiers of interest to devops and infradev - ripienaar
A friendly package manager for R. Contribute to ankane
A command line tool to install base16 templates and set themes globally. - base16-manager
also, bas16-universal-manager exists, which supposedly can change themes for all supported templates, but did not work for me so far.