Skip to content

Instantly share code, notes, and snippets.

View Shipaaaa's full-sized avatar
🤘

Shipaaaa Shipaaaa

🤘
View GitHub Profile
@gabrielemariotti
gabrielemariotti / Readme.md
Last active January 1, 2025 22:35
A SimpleSectionedRecyclerViewAdapter: use this class to realize a simple sectioned `RecyclerView.Adapter`.

You can use this class to realize a simple sectioned RecyclerView.Adapter without changing your code.

The RecyclerView should use a LinearLayoutManager. You can use this code also with the TwoWayView with the ListLayoutManager (https://github.com/lucasr/twoway-view)

This is a porting of the class SimpleSectionedListAdapter provided by Google

Screen

Example:

@illuzor
illuzor / .gitlab-ci.yml
Last active December 2, 2024 08:47
Config for gitlab ci android with unit tests and instrumented tests
image: ubuntu:22.04
variables:
ANDROID_COMPILE_SDK: "33"
ANDROID_BUILD_TOOLS: "33.0.2"
EMULATOR_IMAGE: "24"
SDK_TOOLS: "9477386" # from https://developer.android.com/studio/#command-tools
before_script:
@archi144
archi144 / lab1_1.cpp
Last active October 11, 2019 21:11
Работа над/с ошибками
#include <iostream>
#include <stdio.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <errno.h>
#include <cstring>
using namespace std;
int main()
@osipxd
osipxd / CachingRxJava2CallAdapterFactory.kt
Last active September 15, 2022 07:41
Caching RxJava2 call adapter for Retrofit2
package retrofit2.adapter.rxjava2
import io.reactivex.Completable
import io.reactivex.Flowable
import io.reactivex.Maybe
import io.reactivex.Observable
import io.reactivex.Single
import retrofit2.Call
import retrofit2.CallAdapter
import retrofit2.Retrofit
@osipxd
osipxd / DetailsFragment.kt
Last active May 13, 2020 11:46
Partial view state rendering with LiveData transformations
class DetailsFragment : BaseFragment(R.layout.fragment_details) {
lateinit val viewModel: DetailsViewModel
// ...
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onVewCreated(view, savedInstanceState)
// Assumed that viewModel initialized here
@Shipaaaa
Shipaaaa / Knock_Knock!_Who_s_there?_Open.md
Last active July 2, 2021 07:07
Источники и полезные материалы к докладу "Тук-тук! Кто там? Открыто…"
@osipxd
osipxd / tooling.md
Last active March 22, 2022 12:56
Tooling. Tips&Tricks - Notes

Tooling. Tips&Tricks

Материалы к докладу на митап Redmadrobot 30 апреля.

Habr | YouTube | Презентация

Git

  • Merging vs. Rebasing - сравнение подходов с merge и rebase от Atlassian. У них вообще много хороших статей, очень советую.
  • Why you should stop using Git rebase - какие сложности могут возникнуть, если чрезмерно увлечься rebase.
  • Pro Git. Git Tools - Rewriting History - глава из книги Pro Git. Подробно описывается работа с interactive rebase. Про stash, patch, cherry-pick можно почитать там же.
@osipxd
osipxd / Tooling.Tips&Tricks.key
Last active June 22, 2020 16:23
Tooling. Tips&Tricks - Presentation
This file has been truncated, but you can view the full file.