Ionic Pro: Could not read from remote repository


#1

Hi all,

When I try to link my app to Ionic Pro I’m getting an fault.
I’ve linked the app.

After that I’ve to run for an connect existing app the following:

git push ionic master

While running that getting this message:

Thijmen@MSI MINGW64 ~/Desktop/ionic-old (master)
$ git push ionic master
Warning: Permanently added the ECDSA host key for IP address '35.160.140.25' to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

Hope some one can help me out.

Thanks


#2

I think your public private key wasn’t set up correctly.


#3

I’ve setted my SSH key now.

While rerunning the command I get:

$ git push ionic master
Counting objects: 26690, done.
Connection to git.ionicjs.com closed by remote host.
fatal: The remote end hung up unexpectedly

#4

Now that’s a different one. Suspect having a problem having a secure connection.


#5

Yeah, got it running now.
But ionic is giving me a speed of 17.00 KiB/s.

Edit:
Writing objects: 3% (1036/26690), 5.12 MiB | 8.00 KiB/s


#6

You’re on your own for that one I’m afraid. :slight_smile:


#7

Yeah, probably. It’s useless this push speed.
Taking ages to push 450MB.

Edit:
Nice, it shuts down with the following message

Connection to git.ionicjs.com closed by remote host.0 KiB/s
Wrifatal: The remoteti ng obejectsn:d hung up  1 8% (u4nex888/2pecte6690dly
fatal: sha1 file '<stdout>' write error: Broken pipe
fatal: The remote end hung up unexpectedly

#8

450mb… what the hell are you uploading.

Whatever your current approach is it’s WRONG!!!
You really should not ever have a need to upload that much.

I’m guessing there’s lots of embedded content. Make that a post-install download.


#9

All my node modules.


#10

Aha MAN!!!

STOP IT!


#11

Never keep node modules under version control


#12

You need to .gitignore the node_modules directory.

If you do a new project (ionic start abc) then copy the .gitignore you’re closer there.
If you’ve already checked it in with the node_modules directory you need to do a little git trickery to get it out as the .gitignore won’t do it.


#13

So, adding it to .gitignore will fix this problem?
How the hell am I going to include the existing node-modules to my project while cloning?
It has so many more modules installed that are not delivered by default.

Which command should I run for removing it? Editted my .gitignore but will not work.


#14

Ionic Pro will run the npm install command for themselves.

NEVER EVER EVER EVER EVER include bundles that are easily downloaded - that’s the whole point of using npm.


#15
git rm -r --cached . 
git add .
git commit -am "Remove ignored files"

Don’t miss the dot on the first command.


#16

Runned these commands.
Now pushed it to my own bitbucket repository.

Now when I want to link it to ionic again it’s giving the same errors:

$ git push ionic master
Counting objects: 26711, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (24714/24714), done.
Killed by signal 2.1% (268/26711)
Writing obfatal: jTects:   1%he remote  (27e3/2n6d hung up u711nex), 2.02 MiB | 30pectedly
fatal: sha1 file '<stdout>' write error: Broken pipe
fatal: The remote end hung up unexpectedly

#17

I think you still have a speed issue (18kb/s would do it lol).

Have a look at this…


#18

Tried everything that has been suggested over there.
No success…

People are talking about large files.
Should I push my platforms or add this one in .gitignore to?


#19

Here’s what you should have as a minimum for your .gitignore…

# Specifies intentionally untracked files to ignore when using Git
# http://git-scm.com/docs/gitignore

*~
*.sw[mnpcod]
*.log
*.tmp
*.tmp.*
log.txt
*.sublime-project
*.sublime-workspace
.vscode/
npm-debug.log*

.idea/
.sourcemaps/
.sass-cache/
.tmp/
.versions/
coverage/
dist/
node_modules/
tmp/
temp/
hooks/
platforms/
plugins/
plugins/android.json
plugins/ios.json
www/
$RECYCLE.BIN/

.DS_Store
Thumbs.db
UserInterfaceState.xcuserstate


#20

Why should I remove plugins/ from my repo?