zakariagatter / i3blocks-gate Goto Github PK
View Code? Open in Web Editor NEWExtra i3blocks Scripts For arch Ubuntu very simple and very useful -
Extra i3blocks Scripts For arch Ubuntu very simple and very useful -
Hi, I'm using your script to set up my i3bloks but I'm getting the following error.
Error: Could not parse JSON (lexical error: invalid character inside string
Do I need to install anything else?
which font r u using to get the output same as in the images
Thanks for your script!
I tried only battery (./blocks.sh 6) and I got two errors.
My acpi
shows:
lex@lex-N501JW:~/.config/i3blocks/Blocks/Ubuntu$ acpi
Battery 0: Discharging, 93%, discharging at zero rate - will never fully discharge.
And hence (see comma at the end):
lex@lex-N501JW:~/.config/i3blocks/Blocks/Ubuntu$ acpi | awk '{print $4}'| tr -d "%"
93,
And hence I see error:
lex@lex-N501JW:~/.config/i3blocks/Blocks/Ubuntu$ ./blocks.sh 6
./blocks.sh: line 77: [: 93,: integer expression expected
./blocks.sh: line 78: [: 93,: integer expression expected
./blocks.sh: line 79: [: 93,: integer expression expected
./blocks.sh: line 80: [: 93,: integer expression expected
./blocks.sh: line 81: [: 93,: integer expression expected
I fixed this with additional truncate:
acpi | awk '{print $4}'| tr -d "%" | tr -d ","
I see script error:
lex@lex-N501JW:~/.config/i3blocks/Blocks/Ubuntu$ ./blocks.sh 6
./blocks.sh: line 1: =#!/bin/bash: No such file or directory
I found solution here.
Before fix I see:
lex@lex-N501JW:~/.config/i3blocks/Blocks/Ubuntu$ head -1 ./blocks.sh | od -c
0000000 = # ! / b i n / b a s h \n
0000016
After fix I see:
lex@lex-N501JW:~/.config/i3blocks/Blocks/Ubuntu$ head -1 ./blocks.sh | od -c
0000000 # ! / b i n / b a s h \n
0000014
Are you getting the same on Ubuntu 18.04 ?
It may be a dumb qusetion , but I am a complete noob so here it is anyway:
Is there a difference between installing on Ubuntu and Arch?
Any answers will be appreciated.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.