Skip to content

Commit

Permalink
feat(carthage): add carthage support to InstantSearch by removing dep…
Browse files Browse the repository at this point in the history
…endency on cocoapods for local development
  • Loading branch information
spinach committed Jul 31, 2017
1 parent 24fada7 commit 1aa02e2
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 17 deletions.
1 change: 1 addition & 0 deletions CartFile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github "algolia/instantsearch-core-swift" ~> 2.0
2 changes: 2 additions & 0 deletions Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
github "algolia/algoliasearch-client-swift" "4.8.1"
github "algolia/instantsearch-core-swift" "2.0.1"
1 change: 1 addition & 0 deletions Sources/Library/Concrete/View/SearchBarWidget.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import Foundation
import InstantSearchCore
import UIKit

/// Widget that provides a user input for search queries that are directly sent to the Algolia engine. Built on top of `UISearchBar`.
@objc public class SearchBarWidget: UISearchBar, SearchableViewModel, ResettableDelegate, AlgoliaWidget, UISearchBarDelegate {
Expand Down
1 change: 1 addition & 0 deletions Sources/Library/Concrete/View/TextFieldWidget.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import Foundation
import InstantSearchCore
import UIKit

/// Widget that provides a user input for search queries that are directly sent to the Algolia engine. Built on top of `UITextField`.
@objc public class TextFieldWidget: UITextField, SearchableViewModel, ResettableDelegate, AlgoliaWidget, UITextFieldDelegate {
Expand Down
1 change: 1 addition & 0 deletions Sources/Library/InstantSearch.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import Foundation
import InstantSearchCore
import AlgoliaSearch
import UIKit

// ------------------------------------------------------------------------------------------------------
// IMPLEMENTATION NOTES
Expand Down
41 changes: 24 additions & 17 deletions instantsearch.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/* Begin PBXBuildFile section */
287D0A6E1C4B73BD004566D6 /* WidgetTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 287D0A6D1C4B73BD004566D6 /* WidgetTests.swift */; };
28F828881C494B2C00330CF4 /* InstantSearch.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 28F8287D1C494B2C00330CF4 /* InstantSearch.framework */; };
E21DE94F1F2F7DB400EFC4F5 /* InstantSearchCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E21DE94E1F2F7DB400EFC4F5 /* InstantSearchCore.framework */; };
E21DE9511F2F7DCA00EFC4F5 /* AlgoliaSearch.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E21DE9501F2F7DCA00EFC4F5 /* AlgoliaSearch.framework */; };
E2231E951EC9DC0D002FCF82 /* ConfigureInstantSearchTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = E2231E931EC9DBC4002FCF82 /* ConfigureInstantSearchTests.swift */; };
E2231E971EC9F5A7002FCF82 /* Constants.swift in Sources */ = {isa = PBXBuildFile; fileRef = E2231E961EC9F5A7002FCF82 /* Constants.swift */; };
E233BBFD1EBA18C200F5F5E1 /* SwitchWidget.swift in Sources */ = {isa = PBXBuildFile; fileRef = E233BBFC1EBA18C200F5F5E1 /* SwitchWidget.swift */; };
Expand Down Expand Up @@ -100,6 +102,8 @@
28F828821C494B2C00330CF4 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
28F828871C494B2C00330CF4 /* InstantSearchTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = InstantSearchTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
28F8289B1C494BF100330CF4 /* Playground.playground */ = {isa = PBXFileReference; lastKnownFileType = file.playground; name = Playground.playground; path = Example/Playground.playground; sourceTree = "<group>"; };
E21DE94E1F2F7DB400EFC4F5 /* InstantSearchCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = InstantSearchCore.framework; path = Carthage/Build/iOS/InstantSearchCore.framework; sourceTree = "<group>"; };
E21DE9501F2F7DCA00EFC4F5 /* AlgoliaSearch.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AlgoliaSearch.framework; path = Carthage/Build/iOS/AlgoliaSearch.framework; sourceTree = "<group>"; };
E2231E931EC9DBC4002FCF82 /* ConfigureInstantSearchTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ConfigureInstantSearchTests.swift; sourceTree = "<group>"; };
E2231E961EC9F5A7002FCF82 /* Constants.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Constants.swift; sourceTree = "<group>"; };
E233BBFC1EBA18C200F5F5E1 /* SwitchWidget.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SwitchWidget.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -176,6 +180,8 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
E21DE94F1F2F7DB400EFC4F5 /* InstantSearchCore.framework in Frameworks */,
E21DE9511F2F7DCA00EFC4F5 /* AlgoliaSearch.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -205,6 +211,7 @@
28F8288B1C494B2C00330CF4 /* Tests */,
E27B67E21ED339290001FFA7 /* InstantSearchTestsHost */,
28F8289B1C494BF100330CF4 /* Playground.playground */,
E21DE94D1F2F7DB400EFC4F5 /* Frameworks */,
);
sourceTree = "<group>";
};
Expand Down Expand Up @@ -243,6 +250,15 @@
path = Sources;
sourceTree = "<group>";
};
E21DE94D1F2F7DB400EFC4F5 /* Frameworks */ = {
isa = PBXGroup;
children = (
E21DE9501F2F7DCA00EFC4F5 /* AlgoliaSearch.framework */,
E21DE94E1F2F7DB400EFC4F5 /* InstantSearchCore.framework */,
);
name = Frameworks;
sourceTree = "<group>";
};
E27141D31E9F762F00959294 /* ViewController */ = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -459,7 +475,6 @@
28F828791C494B2C00330CF4 /* Frameworks */,
28F8287A1C494B2C00330CF4 /* Headers */,
28F8287B1C494B2C00330CF4 /* Resources */,
E222E5391EC2F9B4003EFB01 /* ShellScript */,
);
buildRules = (
);
Expand Down Expand Up @@ -581,22 +596,6 @@
};
/* End PBXResourcesBuildPhase section */

/* Begin PBXShellScriptBuildPhase section */
E222E5391EC2F9B4003EFB01 /* ShellScript */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${PODS_ROOT}/SwiftLint/swiftlint\"";
};
/* End PBXShellScriptBuildPhase section */

/* Begin PBXSourcesBuildPhase section */
28F828781C494B2C00330CF4 /* Sources */ = {
isa = PBXSourcesBuildPhase;
Expand Down Expand Up @@ -831,6 +830,10 @@
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Carthage/Build/iOS",
);
INFOPLIST_FILE = "$(SRCROOT)/Sources/Library/Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
Expand All @@ -855,6 +858,10 @@
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Carthage/Build/iOS",
);
INFOPLIST_FILE = "$(SRCROOT)/Sources/Library/Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
Expand Down

0 comments on commit 1aa02e2

Please sign in to comment.