Skip to content

Commit

Permalink
added support a SPM
Browse files Browse the repository at this point in the history
  • Loading branch information
kvyatkovskys committed Jan 31, 2021
1 parent da2becf commit 77705b4
Show file tree
Hide file tree
Showing 57 changed files with 427 additions and 356 deletions.
7 changes: 7 additions & 0 deletions .swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion Example/KVKCalendar/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,10 @@ final class ViewController: UIViewController {
style.timeline.widthEventViewer = 350
style.headerScroll.fontNameDay = .systemFont(ofSize: 17)
}
style.month.scrollDirection = .horizontal
style.month.scrollDirection = .vertical
style.startWeekDay = .sunday
style.timeSystem = TimeHourSystem.current ?? .twelve
style.month.isPagingEnabled = false
if #available(iOS 13.0, *) {
style.event.iconFile = UIImage(systemName: "paperclip")
}
Expand Down
4 changes: 2 additions & 2 deletions Example/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PODS:
- KVKCalendar (0.3.9)
- KVKCalendar (0.4.5)

DEPENDENCIES:
- KVKCalendar (from `../`)
Expand All @@ -9,7 +9,7 @@ EXTERNAL SOURCES:
:path: "../"

SPEC CHECKSUMS:
KVKCalendar: 0e88bbd69c76632a29c0fd462613b20753bcafba
KVKCalendar: b4af1ee6652c04df5a230a4b1c6d2311174685e1

PODFILE CHECKSUM: cd2c6b494eec4d8d293bf0deac29fbac525b56f2

Expand Down
12 changes: 6 additions & 6 deletions Example/Pods/Local Podspecs/KVKCalendar.podspec.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Example/Pods/Manifest.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

647 changes: 324 additions & 323 deletions Example/Pods/Pods.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion KVKCalendar.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Pod::Spec.new do |s|
s.source = { :git => 'https://github.com/kvyatkovskys/KVKCalendar.git', :tag => s.version.to_s }
s.social_media_url = 'https://github.com/kvyatkovskys'
s.ios.deployment_target = '10.0'
s.source_files = 'KVKCalendar/Classes/*.swift'
s.source_files = 'Sources/**/*.swift'
s.frameworks = 'UIKit', 'EventKit'
s.swift_version = '5.0'
end
Empty file removed KVKCalendar/Classes/.gitkeep
Empty file.
31 changes: 31 additions & 0 deletions Package.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// swift-tools-version:5.3
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription

let package = Package(
name: "KVKCalendar",
defaultLocalization: "en",
platforms: [.iOS(.v10)],
products: [
// Products define the executables and libraries a package produces, and make them visible to other packages.
.library(
name: "KVKCalendar",
targets: ["KVKCalendar"]),
],
dependencies: [
// Dependencies declare other packages that this package depends on.
// .package(url: "", from: "1.0.0"),
],
targets: [
// Targets are the basic building blocks of a package. A target can define a module or a test suite.
// Targets can depend on other targets in this package, and on products in packages this package depends on.
.target(
name: "KVKCalendar",
dependencies: []),
.testTarget(
name: "KVKCalendarTests",
dependencies: ["KVKCalendar"]),
],
swiftLanguageVersions: [.version("5.0")]
)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ final class MonthData: EventDateProtocol {
}

func updateSelectedDates(_ dates: Set<Date>, date: Date, calendar: Calendar) -> Set<Date> {
// works only in one month
// works only in the same month
if selectedDates.contains(where: { $0.month != date.month || $0.year != date.year }) {
return [date]
}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
15 changes: 15 additions & 0 deletions Tests/KVKCalendarTests/KVKCalendarTests.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import XCTest
@testable import KVKCalendar

final class KVKCalendarTests: XCTestCase {
func testExample() {
// This is an example of a functional test case.
// Use XCTAssert and related functions to verify your tests produce the correct
// results.
XCTAssertEqual(KVKCalendar().text, "Hello, World!")
}

static var allTests = [
("testExample", testExample),
]
}
9 changes: 9 additions & 0 deletions Tests/KVKCalendarTests/XCTestManifests.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import XCTest

#if !canImport(ObjectiveC)
public func allTests() -> [XCTestCaseEntry] {
return [
testCase(KVKCalendarTests.allTests),
]
}
#endif
7 changes: 7 additions & 0 deletions Tests/LinuxMain.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import XCTest

import KVKCalendarTests

var tests = [XCTestCaseEntry]()
tests += KVKCalendarTests.allTests()
XCTMain(tests)

0 comments on commit 77705b4

Please sign in to comment.