Skip to content

Commit

Permalink
Using python3.5, and all that comes with it
Browse files Browse the repository at this point in the history
  • Loading branch information
rckclmbr committed Feb 7, 2016
1 parent f1a74a4 commit ebf9df2
Show file tree
Hide file tree
Showing 35 changed files with 1,500 additions and 532 deletions.
6 changes: 2 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
language: python
python:
- "2.7"
- "3.5"
install:
- "wget -O - http://apt.mopidy.com/mopidy.gpg | sudo apt-key add -"
- "sudo wget -O /etc/apt/sources.list.d/mopidy.list http://apt.mopidy.com/mopidy.list"
- "sudo apt-get update"
- "sudo apt-get install python-all-dev libffi-dev libspotify-dev pandoc"
- "sudo apt-get install python-all-dev pandoc"
- "pandoc -f markdown -t rst -o README.rst README.md"
- "pip install tox"
script: tox
Expand Down
10 changes: 3 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,9 @@ FROM ubuntu:15.04

MAINTAINER Josh Braegger <rckclmbr@gmail.com>

RUN apt-get update && apt-get install -y curl
RUN curl -s https://apt.mopidy.com/mopidy.gpg | apt-key add -; \
curl -s https://apt.mopidy.com/mopidy.list > /etc/apt/sources.list.d/mopidy.list; \
apt-get update

RUN apt-get install -y python-pip python-dev libffi-dev libspotify-dev
RUN pip install virtualenv && virtualenv --system-site-packages /ve
RUN apt-get update
RUN apt-get install -y python3 python3-pip git
RUN pip3 install virtualenv && virtualenv -p python3 /ve

ADD . /app/
RUN touch /app/README.rst
Expand Down
20 changes: 5 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,35 +20,25 @@ If you are unable to sign in to your Google account, turn on access for less sec
Install
-------

OS X:
OS X / Debian and :

```bash
# Install libspotify
$ brew install homebrew/binary/libspotify
$ brew install libffi
# Workaround on OSX (see https://pyspotify.mopidy.com/en/latest/installation/)
$ ln -s /usr/local/opt/libspotify/lib/libspotify.12.1.51.dylib \
/usr/local/opt/libspotify/lib/libspotify
# Install pyportify
$ pip install pyportify
$ brew install python3
$ pip3 install pyportify
```

Ubuntu:

```bash
curl -s https://apt.mopidy.com/mopidy.gpg | sudo apt-key add -
sudo sh -c 'curl -s https://apt.mopidy.com/mopidy.list > /etc/apt/sources.list.d/mopidy.list'
sudo apt-get update
sudo apt-get install -y python-pip python-dev libffi-dev libspotify-dev
sudo pip install pyportify
sudo apt-get install -y python-pip3
sudo pip3 install pyportify
```

Fedora

```bash
yum -y localinstall --nogpgcheck http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
sudo yum check-update
sudo yum -y install gcc python-pip python-devel libffi-devel libspotify-devel
sudo pip install pyportify
```

Expand Down
6 changes: 6 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: '2'
services:
web:
build: .
ports:
- "3132:3132"
8 changes: 8 additions & 0 deletions make_exe.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash

#PYTHONPATH=. pyinstaller --onefile pyportify/views.py
#PYTHONPATH=. pyinstaller --onefile pyportify/copy_all.py
PYTHONPATH=. pyinstaller pyportify.spec
#mv dist/copy_all dist/pyportify-copyall
#cp -R pyportify/static dist/

51 changes: 51 additions & 0 deletions pyportify.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# -*- mode: python -*-

block_cipher = None

a = Analysis(['pyportify/server.py'],
pathex=['/Users/jbraeg/projects/pyportify'],
binaries=None,
datas=[
('pyportify/static', 'pyportify'),
],
hiddenimports=[],
hookspath=[],
runtime_hooks=[],
excludes=[],
win_no_prefer_redirects=False,
win_private_assemblies=False,
cipher=block_cipher)
pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher)
exe = EXE(pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
name='pyportify',
debug=False,
strip=False,
upx=True,
console=True)

a1 = Analysis(['pyportify/copy_all.py'],
pathex=['/Users/jbraeg/projects/pyportify'],
binaries=None,
datas=None,
hiddenimports=['pyportify', 'pyportify.server'],
hookspath=[],
runtime_hooks=[],
excludes=[],
win_no_prefer_redirects=False,
win_private_assemblies=False,
cipher=block_cipher)
pyz1 = PYZ(a1.pure, a1.zipped_data, cipher=block_cipher)
exe1 = EXE(pyz,
a1.scripts,
a1.binaries,
a1.zipfiles,
a1.datas,
name='pyportify-copyall',
debug=False,
strip=False,
upx=True,
console=True)
2 changes: 1 addition & 1 deletion pyportify/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '0.2.9'
__version__ = '0.3.0'
Loading

0 comments on commit ebf9df2

Please sign in to comment.