manrajgrover / football-cli Goto Github PK
View Code? Open in Web Editor NEW⚽ Command line interface for Hackers who love football
License: MIT License
⚽ Command line interface for Hackers who love football
License: MIT License
Reference here
football-data.org
has released version 2 of its API and is recommended to migrate to it.
Read more here:
https://www.football-data.org/blog
I would love to use this application to see scores for the current 2018/2019 season. Is that possible?
Case where there are multiple groups in standings is currently not handled. This needs to be fixed.
/Users/manrajsingh/Github/football-cli/helpers.js:222
for (let team of group) {
^
TypeError: group is not iterable
at standings (/Users/manrajsingh/Github/football-cli/helpers.js:222:24)
at Request.request [as _callback] (/Users/manrajsingh/Github/football-cli/cli.js:197:9)
at Request.self.callback (/Users/manrajsingh/Github/football-cli/node_modules/request/request.js:187:22)
at Request.emit (events.js:159:13)
at Request.<anonymous> (/Users/manrajsingh/Github/football-cli/node_modules/request/request.js:1048:10)
at Request.emit (events.js:159:13)
at IncomingMessage.<anonymous> (/Users/manrajsingh/Github/football-cli/node_modules/request/request.js:969:12)
at IncomingMessage.emit (events.js:164:20)
at endReadableNT (_stream_readable.js:1054:12)
at _combinedTickCallback (internal/process/next_tick.js:138:11)
League standings should be shown
$ football standings -l CL
Thought that it will be nice when a goal happen, the cli can push a terminal notification. Is it possible?
All I get after installing with npm is.
Input: football
Output:
const updateMessage = (TYPE, message = "") => {
^
SyntaxError: Unexpected token =
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:373:25)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object.<anonymous> (/home/knusper/.npm-packages/lib/node_modules/footballcli/cli.js:22:17)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
Write tests for the API
Add PR and Issues template to the project
i cant run sudo football config
, and get notif sudo: football: command not found
i used zsh shell in LinuxMint OS
how to fix this?
› football-cli help
/usr/lib/node_modules/football-cli/index.js:9
fd.getLeagugeFixturesInTimeFrame(424, "n1").then(function(res) {
^
TypeError: fd.getLeagugeFixturesInTimeFrame is not a function
at Object.<anonymous> (/usr/lib/node_modules/football-cli/index.js:9:4)
at Module._compile (internal/modules/cjs/loader.js:1200:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1220:10)
at Module.load (internal/modules/cjs/loader.js:1049:32)
at Function.Module._load (internal/modules/cjs/loader.js:937:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:71:12)
at internal/main/run_main_module.js:17:47
The application to show the help menu, configuration, or standings. But on executing any football-cli command, I get a stacktrace of errors. I have no idea what is causing this.
Running any football-cli command in Arch linux
football fixtures
returns fixture date and time in the original time zone (or maybe UTC?)
use moment.js local() to convert to user's local time
perhaps, add this an option using a flag or toggle in configuration
Happy to open if PR if you like?
Currently, only a subset of fields is shown in standings. We should show full table as output.
NA
NA
NA
Tried install with sudo but no luck. Can provide logs if needed.
`/usr/local/bin/football -> /usr/local/lib/node_modules/footballcli/cli.js
[email protected] postinstall /usr/local/lib/node_modules/footballcli/node_modules/spawn-sync
node postinstall
shell-init: error retrieving current directory: getcwd: cannot access parent directories: Permission denied
path.js:1142
cwd = process.cwd();
^
Error: EACCES: permission denied, uv_cwd
at Error (native)
at Object.resolve (path.js:1142:25)
at startup (bootstrap_node.js:127:32)
at bootstrap_node.js:509:3
/usr/local/lib
└── (empty)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: node postinstall
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'node postinstall'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the spawn-sync package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node postinstall
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs spawn-sync
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls spawn-sync
npm ERR! There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/Tobi/.npm/_logs/2017-05-05T00_02_41_132Z-debug.log
`
I can't get my dad gum amurrican soccer scores
When I try football fixtures -l MLS
, nothing happens
I should be able to see MLS scores.
Should be self-explanatory.
I hope we can add this to the choices available 😄
It would be better to separate commands into modules and then use the modules in the command construction.
https://github.com/yargs/yargs/blob/master/docs/advanced.md#commands
Integrate Travis with the project
Api has changed list of league ids. Need to change those in current repository.
football fixtures -l PL -d 5 -t "Manchester United" -n
In this, what does the -d
refer to?
Currently, only general guidelines for contributing have been added. We need to add instructions on how to setup development environment locally to a separate document.
Currently, output is printed in tabular form on the terminal. It would be good if we can give an option to allow users to output as JSON or CSV.
Explore, if possible, and add support to show knockout fixtures of Champions League as rounds
Handle negative inputs in fixtures
command
Add contribution guidelines under .github folder
Currently, we make use of gif demos, which is cool, but not as cool as svg-term-cli
. Need to explore and move demos to svg based terminal sessions to improve documentation.
This code was written long back, probably when I didn't know much about documentation. While going through the code, I felt there is a need to fix the JSDocs here.
NA
NA
NA
Currently, on refreshing the league list, the rare competitions like World Cup is not added. We should allow user to add manual list of competitions for such occasions.
NA
NA
NA
Currently, only end time scores are shown. For knockout stages, we should add penalty scoreline as well.
BUG REPORT
Bug: {Not able to see upcoming matches for Argentina}
SUGGESTION
Suggestion: {Should be able to see, upcoming matches of team}
Was not able to see upcoming match of argentina, which according to my timezone is today
Should be able to see upcoming match
Have added screenshot
Currently, promise is unhandled. Need to fix it.
When running watch on the cli command, like watch -n 60 football standings --league WC
which runs the command after every 60 seconds, just like refreshing, the output is
watch football standings -l WC
Add colors to Champions League, Europa League etc as well as Relegation zone to output of standings of a league
Today I created a snap of football-cli and this PR will contain a snapcraft.yaml to enable building of an football-cli snap. I've tested the snap to make sure it works as expected, and find no issues so far.
I'd love to hear if you are generally interested in your software being available as a snap and if you could imagine shipping the snapcraft.yaml file in your source repository for easier publishing.
Background info
If you haven't heard of snaps yet, they are self-contained apps, which can be used on a multitude of Linux systems. Via seccomp
, apparmor
and other Linux security features, they provide great security for users, uploads to the store are available within seconds and you have
full control over your relevant stack.
Snaps can be installed by millions of users: Ubuntu 16.04 LTS and later have snapd installed by default and many other Linux distributions, like Arch, Debian, Gentoo, Fedora, openSUSE, OpenEmbedded, Yocto and OpenWRT made snapd (which powers the snap experience) available as well.
Publishing
Uploading to the store can be done via the command line and there are multiple release channels available, so users can choose between for example stable, beta and alpha releases. You could even hook up snapcraft upload with Travis to auto-publish release tags or nightly builds. The process for this is very simple:
Once:
snapcraft login
snapcraft register football
snapcraft push football_<version>.snap --release=beta
If token is invalid, user needs to be informed about it.
Config sample needs to be added and instructions on how to use it needs to be documented.
When viewing the Serie A standings table, one of the columns was not formatted correctly. Could be because the team name is pretty long
football standings -l SA
football standings -l ELC
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.