constantine-fry / rebekka Goto Github PK
View Code? Open in Web Editor NEWRebekka - FTP/FTPS client in Swift.
License: BSD 2-Clause "Simplified" License
Rebekka - FTP/FTPS client in Swift.
License: BSD 2-Clause "Simplified" License
Hi,
I need to upload images to a server via FTP, and try to install "rebekka", but when i enter the command : git submodule add [email protected]:Constantine-Fry/rebekka.git
I've an error :
`Cloning into '/Users/expad/rebekka'...
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.`
Did someone have an idea ?
Best regards
Getting the following error when trying to call testCreate() on the Demo program.
Create directory with result:
false, error: Optional(Error Domain=kCFErrorDomainCFNetwork Code=200 "(null)" UserInfo={kCFFTPStatusCodeKey=550, _kCFStreamErrorCodeKey=550, _kCFStreamErrorDomainKey=6})
What does this error mean and how to fix?
Hi,
i'm really new to swift (and iOS), and I tried your code. It works great except when I try to list an empty folder. Than I get
"fatal error: unexpectedly found nil while unwrapping an Optional value"
When there are files in it, everything work. I'm trying the basic list example:
_session.list(path) {
(resources, error) -> Void in
print("List directory with result:\n\(resources), error: \(error)\n\n")
}
I am getting this error,
nil, error: Optional(Error Domain=kCFErrorDomainCFNetwork Code=200 "(null)" UserInfo={kCFFTPStatusCodeKey=534})
Can you please suggest on how to deal with this?
Hi,
I love using this framework and one thing I can't get my head around is how to upload a uiimage.I know you can upload a photo from your app bundle , but let's say I wanted to upload a uiimage? How would I go about doing that?
Hey everyone.
I'm very new to swift and programming in general. I'm currently working on my first big project and I need to send a .txt file to an FTP server.
I don't really know how to implement this rebekka framework. I get stuck in the first step of the little tutorial.
I'm also wondering if it will still work with the newest updates of swift and Xcode?
I'm also wondering if there is any other way to upload to an FTP server that I should know of?
It wold really be a huge help if someone would describe to me, step by step, what I need to do.
thank you!
The upload method takes a url, which makes sense in the example in your readme. However, is this possible to do from the camera roll on an iOS device?
Hello,
Empty directories throws exception when listing them but i found a workaround to solve the issue and i posted it in issue #10.
But now i'm facing a new bug, i can't upload a file in an empty directory it returns always an error (The app doesn't crash) and when i upload the same file to another filled directory every thing goes fine. I'm using the same code of upload from the documentation.
Can you please try to find out the problem ?
There is a problem while uploading Image from Gallery.
let URL = NSBundle.mainBundle().pathForResource("TestUplaod", ofType: "png", inDirectory: "\(getImagePath)")
Always returning nil
I saved an image in Directory "getImagePath"
I tried to give direct path of image but error still exists..
also tried "URLForResource" but no use.
Kindlly resolve my issue please.
P.S i am trying on Simulator
I'm having an issue when calling the list function from a background thread. I'm using the _session.list function exactly as in the examples and I'm calling that function in a while loop to check for files on server every N seconds. I'm waiting for every list function to finish before calling it again in the loop.
The issue happens on line 73 in file SwiftOperation.swift.
self.currentStream?.close()
The program breaks after a short amount of time with error: Thread X: exc_bad_access code=1 (X = thread number, never equal to 1 obviously since I call it in a non main thread).
Has anyone had this issue, or by any chance already solved it? Thank you.
The title says it all, thanks for the help.
Actually, on iOS 10 the ftp doesn't seem to work when the App goes in background, using a background task, because sometimes any success or error are received.Am I wrong something?
Hello,
Wondering if you've seen or heard of this before. Everything works fine in my app if I upload from my home wifi, or on cellular data from the phone.
Oddly though, when I'm at the office the files do not upload. The result from the session comes back true with no errors. I've checked the FTP server log and when I'm local I see the phone connecting, but the connection is then just closed, no errors, and the app never seems to actually try to perform the upload.
Any thoughts? I'm 100% stumped.
func doUpload(){
print (photos.count)
var configuration = SessionConfiguration()
configuration.host = (config["ftpIP"] as? String)!
configuration.username = (config["ftpUser"] as? String)!
configuration.password = (config["ftpPass"] as? String)!
let session = Session(configuration: configuration)
//Loop through all the photos
for (index,currentPhoto) in photos.enumerate() {
//Load the photo into the FTP handler
let DocumentsDirectory = NSFileManager().URLsForDirectory(.DocumentDirectory, inDomains: .UserDomainMask).first!
let UploadPhotoURL = DocumentsDirectory.URLByAppendingPathComponent("photos/"+currentPhoto.fileName)
session.upload(UploadPhotoURL, path: currentPhoto.fileName) {
(result, error) -> Void in
print("\nUpload file with result: \(result), error: \(error)")
if (result == true){
self.photos[index].uploaded = true
}
if(session.operationQueue.operationCount == 0){
self.cleanupPhotos()
}
}
}
}
Could you provide sample code on how to enable SSL for FTP connection?
I have downloaded the Demo project, but could not find this option on the code.
Thanks!
When i tried to upload file using upload() method of Session Class. It showed me the success. That's alright. But the file saved on server didn't have extension with it's name. That's ambiguous & it's causing an unknown file type. Hence can't preview the file, until it's extension not there.
So, please resolve this issue as it's really important.
apple (sadly) doesn't like FTP any more and CFFTP functions are depreciated with IOS 9, what can be done ????
https://developer.apple.com/library/mac/documentation/CoreFoundation/Reference/CFFTPStreamRef/
ok so i was trying to upgrade my app from ios 9.3 to ios 10 and the whole library was basically corrupted because the functions or methods used in the library were not available so is there a chance this will be upgraded? Thank You
Hello to everybody! I'm totally new with IOs and Swift.
I need an app to connect to ftp address in a specific folder (always the same). I've seen rebekka project but I've been having problems to use it. Please, could you help me to begin with the project? I've read the tutorial in https://github.com/Constantine-Fry/rebekka but I've got problems in first step using git.
I need a tutorial for dummies :D
How can I merge rebekka project with a new swift project?
Thank you in advance!!!
Is there a way to delete files you have uploaded?
If anyone has found a solution please let me know
Thank you!
Is there an API to delete remote directory/file?
Hi,
in a project, I need to cancel an active download session. As the Session class does not provide any cancel method, I tried the following:
The good thing: It cancels the download (in most of the cases - sometimes, the download does continue, which I see from the XCode stats section).
The bad thing: If I start a new session afterwards and call the download method, the completion block is never called, and the download does not work any more :-(
Any ideas? Is my approach to cancel all operations on the queue right or what would you recommend?
Bye,
Wolfgang
I used rebekka to uploaded image on FTP server, but now I want to show progressBar to uploaded image in swift iOS.
Thanks in advance
I can not login ftps (ftp with ssl) server. How can i make TLS acceptence?
I need to incorporate it in swift 4 project. Does it support latest swift version
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.