Skip to content

Instantly share code, notes, and snippets.

View carolinemusyoka's full-sized avatar
:octocat:
so?.let { it -> be (it) }

Carol carolinemusyoka

:octocat:
so?.let { it -> be (it) }
View GitHub Profile
@carolinemusyoka
carolinemusyoka / convertDate.kt
Last active August 7, 2022 13:48
convert date
fun String.convertDate(context: Context): String? {
return try{
// "2021-11=10T16:24:21.579537Z"
val currentLocale = ConfigurationCompat.getLocales(context.resources.configuration)[0]
val inputFormat = SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'", Locale.getDefault())
inputFormat.timeZone = TimeZone.getTimeZone("GMT")
val passedDate: Date = inputFormat.parse(this) as Date
// Form example Mon, Nov *, 2021, 12:10 pm
# Use the latest 2.1 version of CircleCI pipeline process engine.
# See: https://circleci.com/docs/2.0/configuration-reference
# For a detailed guide to building and testing on Android, read the docs:
# https://circleci.com/docs/2.0/language-android/ for more details.
version: 2.1
# Orbs are reusable packages of CircleCI configuration that you may share across projects, enabling you to create encapsulated, parameterized commands, jobs, and executors that can be used across multiple projects.
# See: https://circleci.com/docs/2.0/orb-intro/
orbs:
android: circleci/[email protected]