Skip to content

Instantly share code, notes, and snippets.

//
// ContentView.swift
// GitStar
//
// Created by EbubekirSezer on 11.10.2022.
//
import SwiftUI
import Apollo
//
// NetworkManager.swift
// GitStar
//
// Created by EbubekirSezer on 19.10.2022.
//
import Foundation
import Apollo
//
// NetworkInterceptorProvider.swift
// GitStar
//
// Created by EbubekirSezer on 19.10.2022.
//
import Foundation
import Apollo
//
// TokenInterceptor.swift
// GitStar
//
// Created by EbubekirSezer on 19.10.2022.
//
import Foundation
import Apollo
import Foundation
import Apollo
protocol NetworkManagerProtocol {
var service: ApolloClient { get set }
func queryGraphQLRequest<T: GraphQLQuery, K: Codable>(query: T, responseModel: K.Type, completion: @escaping ((Result<K, Error>) -> Void))
func performGraphQLRequest<T: GraphQLMutation, K: Codable>(mutation: T, responseModel: K.Type, completion: @escaping ((Result<K, Error>) -> Void))
}
# Type a script or drag a script file from your workspace to insert its path.
# Don't run this during index builds
if [ $ACTION = "indexbuild" ]; then exit 0; fi
# Go to the build root and search up the chain to find the Derived Data Path where the source packages are checked out.
DERIVED_DATA_CANDIDATE="${BUILD_ROOT}"
while ! [ -d "${DERIVED_DATA_CANDIDATE}/SourcePackages" ]; do
if [ "${DERIVED_DATA_CANDIDATE}" = / ]; then
echo >&2 "error: Unable to locate SourcePackages directory from BUILD_ROOT: '${BUILD_ROOT}'"
@ebubekirsezer
ebubekirsezer / SocialMediaButton.swift
Last active January 5, 2022 13:41
SocialMediaButton design
// Created by Ebubekir Sezer on 25.12.2021.
import UIKit
public enum SocialMediaType: String {
case twitter = "twitter"
case facebook = "facebook"
case instagram = "instagram"
}
@ebubekirsezer
ebubekirsezer / DateExtension.swift
Last active January 5, 2022 13:42
Date extension for checking isToday and isYesterday
// Created by Ebubekir Sezer on 25.12.2021.
import Foundation
extension Date {
public var today: Date? { return Calendar.current.date(from: todayComponents) }
public var yesterday: Date { return Date().dayBefore }
public var tomorrow: Date { return Date().dayAfter }
{
"canOpen": true
}
@ebubekirsezer
ebubekirsezer / test_file.txt
Created April 3, 2021 17:46
A brand new Gist
Hello World!