Compare commits

...

13 Commits
1.2 ... main

Author SHA1 Message Date
Shota Shimazu 1bf0af80bb revise 2021-07-30 09:06:43 +09:00
Shota Shimazu 984de192ea Add xcode project file 2021-07-30 08:50:13 +09:00
Shota Shimazu 5968a3aff2 Remove old migrator 2021-07-30 08:45:22 +09:00
Shota Shimazu e0cfd40496 Migrate to travis-ci.com 2021-07-30 08:42:57 +09:00
Shota Shimazu 6ac7090646
Update README.md 2020-02-15 01:32:00 +09:00
Shota Shimazu 2bf41a2cd5
update copyright 2020-02-15 01:27:14 +09:00
Shota Shimazu 65c5237602
upgrade swift version 2020-02-15 01:24:52 +09:00
Shota Shimazu 450ba6cef5
remove xcodeproj from commit list 2020-02-15 01:24:45 +09:00
Shota Shimazu 15ecf990d0
remove xcodeproj 2020-02-15 01:24:32 +09:00
Shota Shimazu 66df0c6376
remove unused ci file 2020-02-15 01:23:06 +09:00
Shota Shimazu 0f36dd90d0
Update LICENSE 2019-01-16 12:21:52 +09:00
shotastage 193e3e01a5
fix inaccessible method 2019-01-16 10:37:53 +09:00
Shota Shimazu e5cc25a31a
WIP: Fix bugs (#5)
* fix internal inaccessible level

Signed-off-by: shotastage <hornet.live.mf@gmail.com>

* update changelog

Signed-off-by: shotastage <hornet.live.mf@gmail.com>

* fix

Signed-off-by: shotastage <hornet.live.mf@gmail.com>

* fix nullable method

Signed-off-by: shotastage <hornet.live.mf@gmail.com>
2019-01-16 10:33:10 +09:00
21 changed files with 785 additions and 673 deletions

View File

@ -1,10 +0,0 @@
image: kylef/swiftenv
before_script:
- swiftenv install https://swift.org/builds/swift-3.1-release/ubuntu1604/swift-3.1-RELEASE/swift-3.1-RELEASE-ubuntu16.04.tar.gz
test:
script:
- swift build
tags:
- vapor

View File

@ -1 +1 @@
4.2
5.1.3

View File

@ -1,5 +1,5 @@
osx_image: xcode10
osx_image: xcode12.5
language: objective-c
xcode_project: Fileable.xcodeproj
xcode_scheme: Fileable
xcode_destination: platform=iOS Simulator,OS=12.0,name=iPhone XS
xcode_scheme: Fileable-Package
xcode_destination: platform=iOS Simulator,OS=14.5,name=iPhone 11

View File

@ -1,3 +1,7 @@
## Version 1.2.1
- Fix internal inaccessible level
## Version 1.2
- Implement get bundle file path method

File diff suppressed because it is too large Load Diff

View File

@ -39,8 +39,6 @@
</BuildableReference>
</TestableReference>
</Testables>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
@ -52,17 +50,6 @@
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "Fileable::Fileable"
BuildableName = "Fileable.framework"
BlueprintName = "Fileable"
ReferencedContainer = "container:Fileable.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"

View File

@ -1,6 +1,6 @@
The MIT License (MIT)
Copyright (c) 2017-2018 Shota Shimazu
Copyright (c) 2017-2019 Shota Shimazu
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

View File

@ -1,4 +1,4 @@
// swift-tools-version:4.0
// swift-tools-version:5.0
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription

View File

@ -1,10 +1,10 @@
![Fileable](./Documentation/filekit_readme.png)
[![Build Status](https://travis-ci.org/shotastage/Fileable.swift.svg?branch=master)](https://travis-ci.org/shotastage/Fileable.swift)
[![Build Status](https://travis-ci.com/shotastage/Fileable.swift.svg?branch=main)](https://travis-ci.com/shotastage/Fileable.swift)
[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/shotasatge/Fileable)
[![Version](https://img.shields.io/cocoapods/v/Fileable.svg?style=flat)](http://cocoapods.org/pods/Fileable)
![iOS 10+](https://img.shields.io/badge/iOS-10%2B-blue.svg?style=flat)
![Swift 4](https://img.shields.io/badge/Swift-4-orange.svg?style=flat)
![Swift 5](https://img.shields.io/badge/Swift-5-orange.svg?style=flat)
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fshotastage%2FFileable.swift.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fshotastage%2FFileable.swift?ref=badge_shield)

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2017/10/25.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on Oct 25, 2017.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation
@ -21,11 +21,11 @@ open class Path {
// Services
#if os(iOS) || os(watchOS) || os(tvOS)
static let ios = FileableIOS.shared
public static let ios = FileableIOS.shared
#endif
#if os(Linux)
static let linux = FileableLinux.shared
public static let linux = FileableLinux.shared
#endif

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2017/10/25.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2019/01/13.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2017/10/25.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2018/12/04.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2017/10/25.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2018/12/09.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2018/12/09.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation

View File

@ -1,31 +0,0 @@
//
// Old.swift
// Fileable
//
// Created by Shota Shimazu on 2017/10/25.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
//
import Foundation
#if os(iOS) || os(watchOS) || os(tvOS)
extension Path {
///
/// Deprecated methods
///
@available(*, unavailable, renamed: "IOSDirs.document.path")
static func appDocument() -> String {
fatalError("appDocument is deprecated!")
}
@available(*, unavailable, renamed: "IOSDirs.cache.path")
static func appCache() -> String {
fatalError("appCache is deprecated!")
}
}
#endif

View File

@ -3,7 +3,7 @@
// Fileable
//
// Created by Shota Shimazu on 2018/12/09.
// Copyright © 2017-2019 Shota Shimazu. All rights reserved.
// Copyright © 2017-2020 Shota Shimazu. All rights reserved.
//
import Foundation
@ -18,9 +18,9 @@ open class FileableIOS {
private init() { }
static func getBundle(file: String) -> String {
public func getBundle(file: String) -> String? {
let path = Bundle.main.path(forResource: file.components(separatedBy: ".")[0] , ofType: file.components(separatedBy: ".")[1])!
let path = Bundle.main.path(forResource: file.components(separatedBy: ".")[0] , ofType: file.components(separatedBy: ".")[1])
return path
}
@ -38,6 +38,7 @@ public enum IOSDirs {
/// path propaty returns directory path as String type
@available(iOS 10.0, *)
var path: String! {
switch self {

View File

@ -43,6 +43,13 @@ class IOSDirsTest: XCTestCase {
XCTAssertTrue(cacheDirectory.contains("Library/Caches"))
XCTAssertTrue(tmpDirectory.contains("tmp"))
}
func testGetBundleFile() {
let path = Path.ios.getBundle(file: "unlocated.txt")
XCTAssertNil(path)
}
func testPerformanceExample() {