Comments (36)
I will back to this when other known problem get fixed.
from ydiff.
are you looking for contributes to this project?
what would you want the setup.py to do?
from ydiff.
I'd like it just to provide setup.py install
propely and Something for publishing to pypi but there I don't know what Something is yet
from ydiff.
ok, ive created a setup.py script and added the project to pypi
http://pypi.python.org/pypi?:action=display&name=cdiff&version=0.0.1
from ydiff.
- I'm not sure if it is a good idea to publish on pypi if you aren't the author
- setup.py is missing license declaration
- have you actually tried to install it from pypi? It doesn't work for me. I suspect the reason is missin python versions support declarations
- README formatting on pypi is broken
- README needs updating of the installation section
from ydiff.
- no problems, i will remove the package and let you publish it as author.
- added licence
- i tried installing via "sudo python setup.py install" it is working for me.
- removing pypi for you to add
- will update README installation section
You should make a .tar.gz file for PyPi to work/
from ydiff.
done, i submitted a pull request with all my changes
from ydiff.
- I DONT know if this is an issue. I have never done this before and don't know much about pypi publishing. I just see there a potential for issues and it doesnt feel kosher to me atm.
- so you tested it install via setup.py directly but not if it can be installed from pypi directly with eg. pip
- I'm not the author either
from ydiff.
i removed the package from PyPi,
there was problem with the package because it was a direct URL to github,
it should be a .tar.gz file.
as far as i understand.. :)
in setup.py
url = "https://github.com/ymattw/cdiff" <--- should be a link to a .tar.gz file
from ydiff.
- How did you figured it's GPL2? I don't see it.
EDIT: D'oh, the COPYING file.
from ydiff.
Thank you all for your kind support, I am in UTC+8 timezone so might not
able to response timely.
Sure I will publish to pypi, contributes are very welcome of course. In my
mind publishing to pypi requires this project to be in high quality, means
I need to write more tests and document to get ready to take patch from
more contributors fast.
@microto, I reviewed your changes and think I need to keep the curl option
in the installation part as using pip make things more complex at current
stage, also sudo setup.py is not a good practice according to official pypi
guide. I am reviewing other PRs and will get back to your pull request
soon.
@yaccz, I have a COPYING file for GPLv2 in the repo, I am fine to change to
another (e.g. Apache?) if it make everyone more comfortable to reuse, any
suggestion?
Thanks,
Matt
On Sun, Feb 3, 2013 at 1:48 AM, yaccz [email protected] wrote:
How did you figured it's GPL2? I don't see it.
—
Reply to this email directly or view it on GitHubhttps://github.com//issues/1#issuecomment-13034281.
from ydiff.
@ymattw I prefer BSD-3 because it is short, simple and fits my FLOSS projects. I don't like GPL2 because it is sooo long, boring and parts are more of an agitation, and howto instead of a license. I have never actually read the GPL2 but I don't get the point of eg. clause 2.a
I'd also suggest semver.org If you don't know about it yet.
If you plan to postpone publishing on pypi it would be nice to at least have the setup.py and release/<version>
tagged commits
from ydiff.
Thanks for the info, I will look into BSD-3 soon, sorry babysitting today :)
On Sunday, February 3, 2013, yaccz wrote:
@ymattw https://github.com/ymattw I prefer BSD-3 because it is short,
simple and fits my FLOSS projects. I don't like GPL2 because it is sooo
long, boring and parts are more of an agitation, and howto instead of a
license. I have never actually read the GPL2 but I don't get the point of
eg. clause 2.aI'd also suggest semver.org If you don't know about it yet.
If you plan to postpone publishing on pypi it would be nice to at least
have the setup.py and release/ tagged commits—
Reply to this email directly or view it on GitHubhttps://github.com//issues/1#issuecomment-13040543.
from ydiff.
Guys I have added a setup.py but get 403 response on setup.py register
, might this because @microto uploaded one before? Could you help review commit 98f63f6? Thanks.
~/ws/cdiff (master)$ ./setup.py register
running register
running egg_info
writing cdiff.egg-info/PKG-INFO
writing top-level names to cdiff.egg-info/top_level.txt
writing dependency_links to cdiff.egg-info/dependency_links.txt
writing entry points to cdiff.egg-info/entry_points.txt
reading manifest file 'cdiff.egg-info/SOURCES.txt'
writing manifest file 'cdiff.egg-info/SOURCES.txt'
running check
We need to know who you are, so please choose either:
1. use your existing login,
2. register as a new user,
3. have the server generate a new password for you (and email it to you), or
4. quit
Your selection [default 1]:
1
Username: ymattw
Password:
Registering cdiff to http://pypi.python.org/pypi
Server response (403): You are not allowed to store 'cdiff' package information
from ydiff.
It might be due to the previous registration. Just to isolate the issue, try temporarily registering under some fake name.
In any case, you can install directly from the git repository:
$ pip install git+https://github.com/ymattw/cdiff
from ydiff.
Good point, I will update readme and try your suggestion tomorrow, offline
now, thanks.
On Sunday, February 3, 2013, Steven Myint wrote:
It might be due to the previous registration. Just to isolate the issue,
try temporarily registering under some fake name.In any case, you can install directly from the git repository:
$ pip install git+https://github.com/ymattw/cdiff
—
Reply to this email directly or view it on GitHubhttps://github.com//issues/1#issuecomment-13048687.
from ydiff.
By the way, I get a similar error as you when I try registering against some arbitrary existing package. @microto could transfer the cdiff registration to you. (This assumes he can undelete his deletion.)
from ydiff.
In any case, you can install directly from the git repository:
That's quite useless for proper packaging
from ydiff.
What do you mean by proper packaging? The above command is just a convenience that allows users to install from arbitrary repositories instead of manually cloning and running setup.py
.
from ydiff.
I mean distribution package management system. Every PMS from language I have seen (be ruby, python, node, …) sucks big time.
from ydiff.
what should i do? i removed the cdiff project from pypi
is there anything else i should do?
from ydiff.
@microto, to fix this first register it again. Since only you have permission to it currently.
./setup.py register
Then log in to your account on https://pypi.python.org. Go to the cdiff link in your account. Then go to the "Administer the Role assigned to users for this package" link and assign @ymattw as the owner. (You'll have to find out what his username is first.)
from ydiff.
done. :)
from ydiff.
Thanks, register succeeded. I will upload to pypi soon once some document stuff done.
from ydiff.
Hey, anyone know how to write the setup.py to allow install as a module instead of a package and use entry point like this:
entry_points = {
'console_scripts': [
'cdiff = cdiff:main',
],
},
I only see a packages = ['src']
option but this will install it as a package named src
, I don't want to rename src to cdiff or even manage it as a package, I want to keep it simple as just 1 script. So is there a modules = instruction?
from ydiff.
I'm not sure. Python users typically put top-level modules in the root of the repository next to the setup.py
.
from ydiff.
maybe http://docs.python.org/2/distutils/setupscript.html#installing-scripts
also see the 2.6 right below
from ydiff.
That would work. Note that this makes it just an executable script rather than also being an importable module (which is probably fine). Also note that if you choose that route, you can just use distutils
, which is built into Python, rather than third-party setuptools
.
from ydiff.
Thanks, finally this syntax make it install as a importable module with a standalone tool ...
package_dir = {'': 'src'},
packages = [''],
py_modules = ['cdiff'],
scripts = [],
entry_points = {
'console_scripts': [
'cdiff = cdiff:main',
],
},
from ydiff.
I committed above change (forget to refer to issue), now I want to reduce use of 3rd party setuptools but found setup
from distutils.core
does not support entry_points
at all. I can use scripts = ['src/cdiff.py']
but still not perfect, still looking for a workaround to strip the '.py' extension while install as a standalone script.
Warning: Unknown distribution option: 'entry_points'
from ydiff.
One option is to create a symlink and point distutils to the symlink (only).
from ydiff.
Another option is to forgo the entry_points
stuff and create a separate executable that just imports cdiff
and runs cdiff.main()
.
from ydiff.
I prefer to symlink so that it also works if someone download the src/cdiff
directly.
from ydiff.
$ pip install cdiff -r http://testpypi.python.org/pypi
Exception:
Traceback (most recent call last):
File "/Library/Python/2.6/site-packages/pip-1.2.1-py2.6.egg/pip/basecommand.py", line 107, in main
status = self.run(options, args)
File "/Library/Python/2.6/site-packages/pip-1.2.1-py2.6.egg/pip/commands/install.py", line 230, in run
for req in parse_requirements(filename, finder=finder, options=options):
File "/Library/Python/2.6/site-packages/pip-1.2.1-py2.6.egg/pip/req.py", line 1330, in parse_requirements
req = InstallRequirement.from_line(line, comes_from)
File "/Library/Python/2.6/site-packages/pip-1.2.1-py2.6.egg/pip/req.py", line 118, in from_line
return cls(req, comes_from, url=url)
File "/Library/Python/2.6/site-packages/pip-1.2.1-py2.6.egg/pip/req.py", line 43, in __init__
req = pkg_resources.Requirement.parse(req)
File "/Library/Python/2.6/site-packages/distribute-0.6.34-py2.6.egg/pkg_resources.py", line 2678, in parse
reqs = list(parse_requirements(s))
File "/Library/Python/2.6/site-packages/distribute-0.6.34-py2.6.egg/pkg_resources.py", line 2591, in parse_requirements
raise ValueError("Missing distribution spec", line)
ValueError: ('Missing distribution spec', '<?xml version="1.0" encoding="utf-8"?>')
Storing complete log in /Users/ymattw/Library/Logs/pip.log
from ydiff.
Ok... testpypi sucks. I uploaded to pypi and pip install cdiff
works. I am going to close this, I am still missing a ChangeLog, better versioning and install/uninstall, but keep them later.
Thanks all for your kind support!
~/ws/cdiff (master)$ sudo pip install cdiff
Password:
Downloading/unpacking cdiff
Downloading cdiff-0.0.1.tar.gz
Running setup.py egg_info for package cdiff
WARNING: '' not a valid package name; please use only.-separated package names in setup.py
Installing collected packages: cdiff
Running setup.py install for cdiff
WARNING: '' not a valid package name; please use only.-separated package names in setup.py
changing mode of build/scripts-2.6/cdiff from 644 to 755
changing mode of /usr/local/bin/cdiff to 755
Successfully installed cdiff
Cleaning up...
~/ws/cdiff (master)$ which cdiff
/usr/local/bin/cdiff
from ydiff.
Kudos & thanks
from ydiff.
Related Issues (20)
- How to use ydiff in "git add -p"? HOT 2
- Request: expose basic diff command as a callable HOT 4
- Unable to diff two local files? HOT 2
- Highlight just changed characters, not lines.
- Apt package? HOT 2
- side-by-side becomes unified when disabling color HOT 7
- Using "git difftool --extcmd="ydiff" displayes temporary file names HOT 3
- Hang on large files HOT 5
- Replace legacy distutils by... setuptools? HOT 7
- Navigate to next hunk HOT 3
- " brew install ydiff " doesnt work HOT 2
- Fedora package HOT 6
- Customize colors HOT 3
- Configurable pager behaviour (auto/always/never) HOT 13
- Heads-up: FreeBSD package
- configure default to side by side HOT 4
- Stdin only works if in a VCS HOT 1
- Tabs are not expanded correctly in `-s` mode
- How to use on Windows HOT 4
- Highlight changes instead of underlining them HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ydiff.